diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 000000000000..8d275ce31aa3 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,27 @@ +// Place your settings in this file to overwrite default and user settings. +{ + // Unofficially, QMK uses spaces for indentation + "editor.insertSpaces": true, + // Configure glob patterns for excluding files and folders. + "files.exclude": { + "**/.build": true, + "**/*.hex": true, + "**/*.bin": true + }, + "files.associations": { + "*.h": "c", + "*.c": "c", + "*.inc": "c", + "*.cpp": "cpp", + "*.hpp": "cpp", + "xstddef": "c", + "type_traits": "c", + "utility": "c", + "ranges": "c" + }, + "[markdown]": { + "editor.trimAutoWhitespace": false, + "files.trimTrailingWhitespace": false + }, + "python.formatting.provider": "yapf" +} diff --git a/bin/qmk b/bin/qmk index a6e8ce08daca..617f99282642 100755 --- a/bin/qmk +++ b/bin/qmk @@ -35,6 +35,7 @@ def main(): print('Warning: The bin/qmk script is being deprecated. Please install the QMK CLI: python3 -m pip install qmk', file=sys.stderr) # Import the subcommands + import milc.subcommand.config # noqa import qmk.cli # noqa # Execute diff --git a/bootloader.mk b/bootloader.mk index 79d3c3d72ab2..4f2d69d9985a 100644 --- a/bootloader.mk +++ b/bootloader.mk @@ -90,7 +90,7 @@ ifeq ($(strip $(BOOTLOADER)), USBasp) endif ifeq ($(strip $(BOOTLOADER)), lufa-ms) OPT_DEFS += -DBOOTLOADER_MS - BOOTLOADER_SIZE = 6144 + BOOTLOADER_SIZE ?= 8192 FIRMWARE_FORMAT = bin cpfirmware: lufa_warning .INTERMEDIATE: lufa_warning diff --git a/docs/breaking_changes.md b/docs/breaking_changes.md index 3e85a70761d2..b0d56a81bd29 100644 --- a/docs/breaking_changes.md +++ b/docs/breaking_changes.md @@ -56,7 +56,7 @@ This happens immediately after the previous `develop` branch is merged. * [ ] `git commit -m 'Branch point for Breaking Change'` * [ ] `git tag breakpoint___
` * [ ] `git tag ` # Prevent the breakpoint tag from confusing version incrementing - * [ ] `git push origin develop` + * [ ] `git push upstream develop` * [ ] `git push --tags` ## 4 Weeks Before Merge @@ -86,13 +86,17 @@ This happens immediately after the previous `develop` branch is merged. * `qmk_firmware` git commands * [ ] `git checkout develop` * [ ] `git pull --ff-only` - * [ ] `git rebase origin/master` * [ ] Edit `readme.md` * [ ] Remove the notes about `develop` * [ ] Roll up the ChangeLog into one file. * [ ] `git commit -m 'Merge point for Breaking Change'` - * [ ] `git push origin develop` + * [ ] `git push upstream develop` * GitHub Actions * [ ] Create a PR for `develop` * [ ] Make sure travis comes back clean - * [ ] Merge `develop` PR + * [ ] **Turn off 'Automatically delete head branches' for the repository** -- confirm with @qmk/directors that it is done before continuing +* `qmk_firmware` git commands + * [ ] `git checkout master` + * [ ] `git pull --ff-only` + * [ ] `git merge --no-ff develop` + * [ ] `git push upstream master` diff --git a/docs/feature_audio.md b/docs/feature_audio.md index b7b572974fdc..9ffbc2cba82d 100644 --- a/docs/feature_audio.md +++ b/docs/feature_audio.md @@ -131,12 +131,14 @@ You can override the default songs by doing something like this in your `config. ```c #ifdef AUDIO_ENABLE - #define STARTUP_SONG SONG(STARTUP_SOUND) +# define STARTUP_SONG SONG(STARTUP_SOUND) #endif ``` A full list of sounds can be found in [quantum/audio/song_list.h](https://github.com/qmk/qmk_firmware/blob/master/quantum/audio/song_list.h) - feel free to add your own to this list! All available notes can be seen in [quantum/audio/musical_notes.h](https://github.com/qmk/qmk_firmware/blob/master/quantum/audio/musical_notes.h). +Additionally, if you with to maintain your own list of songs (such as ones that may be copyrighted) and not have them added to the repo, you can create a `user_song_list.h` file and place it in your keymap (or userspace) folder. This file will be automatically included, it just needs to exist. + To play a custom sound at a particular time, you can define a song like this (near the top of the file): ```c diff --git a/docs/feature_led_matrix.md b/docs/feature_led_matrix.md index 9c3e2c7f3d21..5134ab6efac7 100644 --- a/docs/feature_led_matrix.md +++ b/docs/feature_led_matrix.md @@ -67,6 +67,8 @@ Where `Cx_y` is the location of the LED in the matrix defined by [the datasheet] --- +## Common Configuration :id=common-configuration + From this point forward the configuration is the same for all the drivers. The `led_config_t` struct provides a key electrical matrix to led index lookup table, what the physical position of each LED is on the board, and what type of key or usage the LED if the LED represents. Here is a brief example: ```c diff --git a/docs/feature_oled_driver.md b/docs/feature_oled_driver.md index d2dc6103a687..f3b659b1bc26 100644 --- a/docs/feature_oled_driver.md +++ b/docs/feature_oled_driver.md @@ -263,22 +263,11 @@ void oled_write(const char *data, bool invert); void oled_write_ln(const char *data, bool invert); // Pans the buffer to the right (or left by passing true) by moving contents of the buffer -// Useful for moving the screen in preparation for new drawing +// Useful for moving the screen in preparation for new drawing // oled_scroll_left or oled_scroll_right should be preferred for all cases of moving a static // image such as a logo or to avoid burn-in as it's much, much less cpu intensive void oled_pan(bool left); -// Writes a PROGMEM string to the buffer at current cursor position -// Advances the cursor while writing, inverts the pixels if true -// Remapped to call 'void oled_write(const char *data, bool invert);' on ARM -void oled_write_P(const char *data, bool invert); - -// Writes a PROGMEM string to the buffer at current cursor position -// Advances the cursor while writing, inverts the pixels if true -// Advances the cursor to the next page, wiring ' ' to the remainder of the current page -// Remapped to call 'void oled_write_ln(const char *data, bool invert);' on ARM -void oled_write_ln_P(const char *data, bool invert); - // Returns a pointer to the requested start index in the buffer plus remaining // buffer length as struct oled_buffer_reader_t oled_read_raw(uint16_t start_index); @@ -289,13 +278,24 @@ void oled_write_raw(const char *data, uint16_t size); // Writes a single byte into the buffer at the specified index void oled_write_raw_byte(const char data, uint16_t index); -// Writes a PROGMEM string to the buffer at current cursor position -void oled_write_raw_P(const char *data, uint16_t size); - // Sets a specific pixel on or off // Coordinates start at top-left and go right and down for positive x and y void oled_write_pixel(uint8_t x, uint8_t y, bool on); +// Writes a PROGMEM string to the buffer at current cursor position +// Advances the cursor while writing, inverts the pixels if true +// Remapped to call 'void oled_write(const char *data, bool invert);' on ARM +void oled_write_P(const char *data, bool invert); + +// Writes a PROGMEM string to the buffer at current cursor position +// Advances the cursor while writing, inverts the pixels if true +// Advances the cursor to the next page, wiring ' ' to the remainder of the current page +// Remapped to call 'void oled_write_ln(const char *data, bool invert);' on ARM +void oled_write_ln_P(const char *data, bool invert); + +// Writes a PROGMEM string to the buffer at current cursor position +void oled_write_raw_P(const char *data, uint16_t size); + // Can be used to manually turn on the screen if it is off // Returns true if the screen was on or turns on bool oled_on(void); diff --git a/docs/feature_rgb_matrix.md b/docs/feature_rgb_matrix.md index 169443fb85a5..bfb3688b6778 100644 --- a/docs/feature_rgb_matrix.md +++ b/docs/feature_rgb_matrix.md @@ -229,6 +229,8 @@ Configure the hardware via your `config.h`: --- +## Common Configuration :id=common-configuration + From this point forward the configuration is the same for all the drivers. The `led_config_t` struct provides a key electrical matrix to led index lookup table, what the physical position of each LED is on the board, and what type of key or usage the LED if the LED represents. Here is a brief example: ```c diff --git a/docs/feature_split_keyboard.md b/docs/feature_split_keyboard.md index bc09b2a5ccc9..4ebf585f5c1f 100644 --- a/docs/feature_split_keyboard.md +++ b/docs/feature_split_keyboard.md @@ -60,6 +60,7 @@ The 3 wires of the TRS/TRRS cable need to connect GND, VCC, and D0/D1/D2/D3 (aka The 4 wires of the TRRS cable need to connect GND, VCC, and SCL and SDA (aka PD0/pin 3 and PD1/pin 2, respectively) between the two Pro Micros. The pull-up resistors may be placed on either half. If you wish to use the halves independently, it is also possible to use 4 resistors and have the pull-ups in both halves. +Note that the total resistance for the connected system should be within spec at 2.2k-10kOhm, with an 'ideal' at 4.7kOhm, regardless of the placement and number. sk-i2c-connection-mono diff --git a/docs/ja/_summary.md b/docs/ja/_summary.md index d6b67440a2f2..55a239f5b7f8 100644 --- a/docs/ja/_summary.md +++ b/docs/ja/_summary.md @@ -155,6 +155,7 @@ * [QMK への貢献](ja/contributing.md) * [QMK ドキュメントの翻訳](ja/translating.md) * [設定オプション](ja/config_options.md) + * [データ駆動型コンフィギュレーション](ja/data_driven_config.md) * [Make ドキュメント](ja/getting_started_make_guide.md) * [ドキュメント ベストプラクティス](ja/documentation_best_practices.md) * [ドキュメント テンプレート](ja/documentation_templates.md) diff --git a/docs/ja/data_driven_config.md b/docs/ja/data_driven_config.md new file mode 100644 index 000000000000..bc8f4d24a542 --- /dev/null +++ b/docs/ja/data_driven_config.md @@ -0,0 +1,123 @@ +# データ駆動型コンフィギュレーション + + + +このページでは、QMK のデータ駆動型 JSON コンフィギュレーションシステムがどのように動作するかを説明します。これは、QMK 自体に取り組みたい開発者を対象としています。 + +## ヒストリー + +これまで、QMK は、`rules.mk` と `config.h` の2つのメカニズムを組み合わせてコンフィギュレーションされてきました。 +この方法は、QMK がほんの一握りのキーボードをサポートしていたときは上手く機能していましたが、今では、サポートするキーボードは1500近くまで成長しました。 +`keyboards` の下だけで6000個の設定ファイルがあることが推定されます。 +これらのファイルの自由形式の性質と、重複を避けるために人々が使用してきたユニークなパターンが継続的なメンテナンスを困難にしており、また、多くのキーボードが時代遅れで時には理解が難しいパターンに従っています。 + +また、CLI に慣れていない人に QMK のパワーを提供することにも取り組んでおり、VIA などの他のプロジェクトでは、プログラムをインストールするのと同じくらい簡単に QMK を使用できるように取り組んでいます。 +これらのツールには、ユーザーが QMK を最大限に活用できるように、キーボードのレイアウト方法や使用可能なピンと機能に関する情報が必要です。 +その第一歩として `info.json` を導入しました。 +QMK API は、これら3つの情報源(`config.h`、` rules.mk`、および `info.json`)を、エンドユーザーツールが使用できる信頼できる単一の情報源に結合するための取り組みです。 + +これで、`info.json`から `rules.mk` と `config.h` の値を生成することがサポートされ、信頼できる単一の情報源を持つことができます。 +これにより、自動化されたツールを使用してキーボードを保守できるため、時間と保守作業を大幅に節約できます。 + +## 概要 + +C 側では何も変わりません。 +新しいルールを作成したり、定義したりする必要がある場合は、同じプロセスに従います。 + +1. `docs/config_options.md` に追加します。 +1. 適切なコアファイルにデフォルトを設定します。 +1. 必要に応じて ifdef 文を追加します。 + +次に、新しい構成のサポートを `info.json` に追加する必要があります。 +基本的なプロセスは次のとおりです。 + +1. `data/schemas/keyboards.jsonschema` のスキーマに追加します +1. `data/maps` にマッピングを追加します +1. (オプションおよび非推奨)構成を抽出/生成するコードを追加します。 + * `lib/python/qmk/info.py` + * `lib/python/qmk/cli/generate/config_h.py` + * `lib/python/qmk/cli/generate/rules_mk.py` + +## info.json にオプションを追加する + +このセクションでは、info.json に `config.h`/`rules.mk` の値のサポートを追加することについて説明します。 + +### スキーマに追加する + +QMK では、[jsonschema](https:json-schema.org) のファイルを `data/schemas` に保持しています。 +キーボード固有の `info.json` ファイルに入る値は `keyboard.jsonschema` に保持されています。 +エンドユーザーが編集できるようにしたい値はすべてここに入れなければなりません。 + +場合によっては、新しいトップレベルキーを追加するだけで済みます。 +従うべきいくつかの例は、 `keyboard_name`、`maintainer`、 `processor`、および `url` です。 +これは、オプションが自己完結型で、他のオプションと直接関係がない場合に適しています。 + +その他の場合、1つの `object` の中に、似ているオプションを集める必要があります。 +これは、機能のサポートを追加する場合に特に当てはまります。 +このために従うべきいくつかの例は、`indicators`、`matrix_pins`、および `rgblight` です。 +新しいオプションを統合する方法がわからない場合は、[問題を開く](https://github.com/qmk/qmk_firmware/issues/new?assignees=&labels=cli%2C+python&template=other_issues.md&title=)か、[Discord で #cli に参加](https://discord.gg/heQPAgy)して、そこで会話を始めてください。 + +### マッピングを追加する + +ほとんどの場合、単純なマッピングを追加することができます。 +これらは `data/mappings/info_config.json` と `data/mappings/info_rules.json` に JSON ファイルとして保持され、それぞれ `config.h` と `rules.mk` のマッピングを制御します。 +各マッピングは `config.h` または `rules.mk` 変数名をキーとし、値は以下のキーを持つハッシュです。 + +* `info_key`: (必須)この値の `info.json` 内の場所。 下記参照。 +* `value_type`: (オプション)デフォルトは `str`。 この変数の値の形式。 下記参照。 +* `to_json`: (オプション)デフォルトは `true`。 このマッピングを info.json から除外するには、`false` に設定します +* `to_c`: (オプション)デフォルトは `true`。 このマッピングを config.h から除外するには、`false` に設定します +* `warn_duplicate`: (オプション)デフォルトは `true`。 値が両方の場所に存在する場合に警告をオフにするには、`false` に設定します + +#### Info Key + +info.json 内の変数をアドレス指定するために JSON ドット表記を使用します。 +たとえば、`info_json["rgblight"]["split_count"]` にアクセスするには、`rgblight.split_count` を指定します。 +これにより、深くネストされたキーを単純な文字列でアドレス指定できます。 + +内部では [Dotty Dict](https://dotty-dict.readthedocs.io/en/latest/) を使用しています。これらの文字列がオブジェクトアクセスに変換される方法についてはそのドキュメントを参照してください。 + +#### Value Types + +デフォルトでは、すべての値を単純な文字列として扱います。 +値がより複雑な場合は、次のいずれかのタイプを使用してデータをインテリジェントに解析できます。 + +* `array`: 文字列のコンマ区切りの配列 +* `array.int`: 整数のコンマ区切り配列 +* `int`: 整数 +* `hex`: 16進数としてフォーマットされた数値 +* `list`: 文字列のスペース区切りの配列 +* `mapping`: キーと値のペアのハッシュ + +### 抽出するコードを追加する + +ほとんどのユースケースは、上記のマッピングファイルによって解決できます。 +できない場合は、代わりに設定値を抽出するコードを書くことができます。 + +QMK が完全な `info.json` を生成するときはいつでも、`config.h` と `rules.mk` から情報を抽出します。 +あなたの新しい設定値のためのコードを `lib/python/qmk/info.py` に追加する必要があります。 +通常、これは、新しい `_extract_()` 関数を追加してから、 `_extract_config_h()` または `_extract_rules_mk()` のいずれかで関数を呼び出すことを意味します。 + +このファイルの編集方法がわからない場合、または Python に慣れていない場合は、[issue を開く](https://github.com/qmk/qmk_firmware/issues/new?assignees=&labels=cli%2C+python&template=other_issues.md&title=)か [Discord で #cli に参加](https://discord.gg/heQPAgy)すると、この部分を誰かが手伝ってくれるでしょう。 + +### 生成するコードを追加する + +パズルの最後のピースは、ビルドシステムに新しいオプションを提供することです。 +これは、2つのファイルを生成することによって行われます。 + +* `.build/obj_/src/info_config.h` +* `.build/obj_/src/rules.mk` + +この2つのファイルは、次のコードによって生成されます。 + +* `lib/python/qmk/cli/generate/config_h.py` +* `lib/python/qmk/cli/generate/rules_mk.py` + +`config.h`値の場合、ルール用の関数を記述し、その関数を `generate_config_h()` で呼び出す必要があります。 + +`rules.mk` の新しいトップレベルの `info.json` キーがある場合は、`lib/python/qmk/cli/generate/rules_mk.py` の上部にある `info_to_rules` にキーを追加するだけです。 +それ以外の場合は、`generate_rules_mk()` で機能の新しい if ブロックを作成する必要があります。 diff --git a/docs/ja/feature_haptic_feedback.md b/docs/ja/feature_haptic_feedback.md index b9b42670147a..158079725329 100644 --- a/docs/ja/feature_haptic_feedback.md +++ b/docs/ja/feature_haptic_feedback.md @@ -1,8 +1,8 @@ # 触覚フィードバック ## 触覚フィードバック の rules.mk オプション @@ -31,7 +31,7 @@ | `HPT_TOG` | 触覚フィードバックのオン/オフを切り替え | | `HPT_RST` | 触覚フィードバック設定をデフォルトに戻す | | `HPT_FBK` | キー押下またはリリースまたはその両方でフィードバックを切り替え | -| `HPT_BUZ` | ソレノイドの振動のオン/オフを切り替え | +| `HPT_BUZ` | ソレノイドのブザー音のオン/オフを切り替え | | `HPT_MODI` | 次の DRV2605L 波形に移動 | | `HPT_MODD` | 前の DRV2605L 波形に移動 | | `HPT_CONT` | 連続触覚モードのオン/オフを切り替え | @@ -44,7 +44,7 @@ ほとんどの MCU はソレノイドのコイルを駆動するために必要な電流を供給できないため、最初に MOSFET を介してソレノイドを駆動する回路を構築する必要があります。 -[Adafruit が提供する配線図](https://playground.arduino.cc/uploads/Learning/solenoid_driver.pdf) +[Adafruit が提供する配線図](https://cdn-shop.adafruit.com/product-files/412/412_solenoid_driver.pdf) | 設定 | デフォルト | 説明 | @@ -53,8 +53,15 @@ | `SOLENOID_DEFAULT_DWELL` | `12` ms | ソレノイドのデフォルトの滞留時間を設定する。 | | `SOLENOID_MIN_DWELL` | `4` ms | 滞留時間の下限を設定する。 | | `SOLENOID_MAX_DWELL` | `100` ms | 滞留時間の上限を設定する。 | - -?> 滞留時間とは、「プランジャー」が作動したままになる時間です。滞留時間により、ソレノイドの音が変わります。 +| `SOLENOID_DWELL_STEP_SIZE` | `1` ms | `HPT_DWL*` キーコードが送信される時に使われるステップサイズ | +| `SOLENOID_DEFAULT_BUZZ` | `0` (無効) | HPT_RST では、この値が "1" の場合、ブザー音が "on" に設定されます | +| `SOLENOID_BUZZ_ACTUATED` | `SOLENOID_MIN_DWELL` | ソレノイドがブザー音モードの場合の動作時間 | +| `SOLENOID_BUZZ_NONACTUATED` | `SOLENOID_MIN_DWELL` | ソレノイドがブザー音モードの場合の非動作時間 | + +* ソレノイドのブザー音がオフの場合、滞留時間は「プランジャー」が作動したままになる時間です。滞留時間により、ソレノイドの音が変わります。 +* ソレノイドのブザー音がオンの場合、滞留時間は振動の長さを設定しますが、`SOLENOID_BUZZ_ACTUATED` と `SOLENOID_BUZZ_NONACTUATED` はブザー音の間の(非)動作時間を設定します。 +* 現在の実装では、上記の時間設定のいずれについても、設定の精度はキーボードがマトリックスをスキャンできる速度によって影響を受ける可能性があります。 + したがって、キーボードのスキャンルーチンが遅い場合は、`SOLENOID_DWELL_STEP_SIZE` をキーボードのスキャンに掛かる時間よりもわずかに小さい値に設定することをお勧めします。 ブートローダ実行中に一部のピンが給電されているかもしれず (例えば、STM32F303 チップ上の A13)、そうすると書き込みプロセスの間ずっとソレノイドがオン状態になることに注意してください。これはソレノイドを加熱し損傷を与えるかもしれません。ソレノイドが接続されているピンがブートローダ/DFU 実行中にソレノイドをオンにしていることが分かった場合は、他のピンを選択してください。 diff --git a/docs/ja/feature_pointing_device.md b/docs/ja/feature_pointing_device.md index f606036d149c..69bd86c55200 100644 --- a/docs/ja/feature_pointing_device.md +++ b/docs/ja/feature_pointing_device.md @@ -1,8 +1,8 @@ # ポインティングデバイス :id=pointing-device ポインティングデバイスは汎用的な機能の総称です: システムポインタを移動します。マウスキーのような他のオプションも確かにありますが、これは簡単に変更可能で軽量であることを目指しています。機能を制御するためにカスタムキーを実装したり、他の周辺機器から情報を収集してここに直接挿入したりできます - QMK に処理を任せてください。 @@ -24,7 +24,7 @@ report_mouse_t (ここでは "mouseReport") が以下のプロパティを持つ * `mouseReport.y` - これは、y軸の動き(+ 上へ、- 下へ)を表す -127 から 127 (128ではなく、USB HID 仕様で定義されています)の符号付き整数です。 * `mouseReport.v` - これは、垂直スクロール(+ 上へ、- 下へ)を表す -127 から 127 (128ではなく、USB HID 仕様で定義されています)の符号付き整数です。 * `mouseReport.h` - これは、水平スクロール(+ 右へ、- 左へ)を表す -127 から 127 (128ではなく、USB HID 仕様で定義されています)の符号付き整数です。 -* `mouseReport.buttons` - これは uint8_t で、上位の5ビットを使っています。これらのビットはマウスボタンの状態を表します - ビット 3 はマウスボタン 5、ビット 7 はマウスボタン 1 です。 +* `mouseReport.buttons` - これは uint8_t で、8ビット全てを使っています。これらのビットはマウスボタンの状態を表します - ビット 0 はマウスボタン 1、ビット 7 はマウスボタン 8 です。 マウスレポートに必要な変更を行ったら、それを送信する必要があります: @@ -32,6 +32,10 @@ report_mouse_t (ここでは "mouseReport") が以下のプロパティを持つ マウスレポートが送信されると、x、y、v、h のいずれの値も 0 に設定されます (これは `pointing_device_send()` で行われます。この挙動を回避するためにオーバーライドすることができます)。このように、ボタンの状態は持続しますが、動きは1度だけ起こります。さらにカスタマイズするために、`pointing_device_init` と `pointing_device_task` のどちらもオーバーライドすることができます。 +さらに、デフォルトでは、`pointing_device_send()` はレポートが実際に変更された場合のみレポートを送信します。これにより、マウスレポートが継続的に送信されてホストシステムが起動されたままになることを防ぎます。この動作は、独自の `pointing_device_send()` 関数を作成することで変更できます。 + +また、`has_mouse_report_changed(new, old)` 関数を使って、レポートが変更されたかどうかを確認できます。(訳注:独自の `pointing_device_send()` 関数を作成する場合でも、その中で `has_mouse_report_changed(new, old)` 関数でチェックして、デフォルトの `pointing_device_send()` と類似の無駄なレポートの抑制をして、ホストシステムがスリープ状態に入れる余地を残すようにしておくのが良いでしょう。) + 以下の例では、カスタムキーを使ってマウスをクリックし垂直および水平方向に127単位スクロールし、リリースされた時にそれを全て元に戻します - なぜならこれは完全に便利な機能だからです。いいですか、以下はひとつの例です: ```c diff --git a/docs/ja/hardware_keyboard_guidelines.md b/docs/ja/hardware_keyboard_guidelines.md index faf021776563..8a9127abc916 100644 --- a/docs/ja/hardware_keyboard_guidelines.md +++ b/docs/ja/hardware_keyboard_guidelines.md @@ -2,12 +2,31 @@ QMK は開始以来、コミュニティにおけるキーボードの作成や保守に貢献しているあなたのような人たちのおかげで飛躍的に成長しました。私たちが成長するにつれて、うまくやるためのいくつかのパターンを発見しました。他の人たちがあなたの苦労の恩恵を受けやすくするため、それにあわせてもらえるようお願いします。 +## QMK Lint を使う + +キーボードの問題をチェックできるツール、`qmk lint` を提供しています。キーボードとキーマップで作業をしている間は、頻繁に使うことをお勧めします。 + +チェックに合格した例: + +``` +$ qmk lint -kb rominronin/katana60/rev2 +Ψ Lint check passed! +``` + +チェックに失敗した例: + +``` +$ qmk lint -kb clueboard/66/rev3 +☒ Missing keyboards/clueboard/66/rev3/readme.md +☒ Lint check failed! +``` + ## あなたのキーボード/プロジェクトの名前を決める キーボードの名前は全て小文字で、アルファベット、数字、アンダースコア(`_`)のみで構成されています。アンダースコア(`_`)で始めてはいけません。スラッシュ(`/`)はサブフォルダの区切り文字として使用されます。 diff --git a/docs/ja/newbs.md b/docs/ja/newbs.md index 1cb2c4f549a9..5fdf40425a7e 100644 --- a/docs/ja/newbs.md +++ b/docs/ja/newbs.md @@ -1,9 +1,9 @@ -# QMK 初心者ガイド +# QMK チュートリアル キーボードには、コンピュータ入っているものと似たようなプロセッサが入っています。 @@ -19,20 +19,16 @@ QMK は、簡単なことは簡単に、そして、難しいことを可能な QMK は[多くの趣味のキーボード](https://qmk.fm/keyboards/)をサポートしています。 現在使用しているキーボードが QMK を実行できない場合、QMK を実行できるキーボードの選択肢はたくさんあります。 -## このガイドは私のためにあるのでしょうか? - -このガイドは、ソースコードを使ってキーボードのファームウェアを構築したいと考えている人に適しています。 -もしあなたがすでにプログラマーであれば、このプロセスはとても身近で簡単に理解できるでしょう。 -もし、プログラミングの考え方に抵抗があるのであれば、代わりに[私たちのオンラインGUI](ja/newbs_building_firmware_configurator.md)を見てみてください。 +?> **このガイドは私のためにあるのでしょうか?**
+もし、プログラミングの考え方に抵抗があるのであれば、代わりに[私たちのオンライン GUI](ja/newbs_building_firmware_configurator.md) を見てみてください。 ## 概要 -このガイドには4つの主要なセクションがあります。 +このガイドは、ソースコードを使ってキーボードのファームウェアを構築したいと考えている人に適しています。 もしあなたがすでにプログラマーであれば、このプロセスはとても身近で簡単に理解できるでしょう。このガイドには3つの主要なセクションがあります: 1. [環境設定](ja/newbs_getting_started.md) 2. [コマンドラインを使用して初めてのファームウェアを構築する](ja/newbs_building_firmware.md) 3. [ファームウェアを書きこむ](ja/newbs_flashing.md) -4. [テストとデバッグ](ja/newbs_testing_debugging.md) このガイドは、これまでソフトウェアをコンパイルしたことがない人を支援することに特化しています。 その観点から選択と推奨を行います。 @@ -41,8 +37,4 @@ QMK は[多くの趣味のキーボード](https://qmk.fm/keyboards/)をサポ ## 追加のリソース -このガイドの他にも、QMK の学習に役立つリソースがいくつかあります。[学習リソース](ja/newbs_learn_more_resources.md)のページにまとめました。 - -## オープンソース - -QMKは GNU General Public License でリリースされているオープンソース・ソフトウェアです。 +このガイドの他にも、QMK の学習に役立つリソースがいくつかあります。[シラバス](ja/syllabus.md)と[学習リソース](ja/newbs_learn_more_resources.md)のページにまとめました。 diff --git a/docs/ja/newbs_flashing.md b/docs/ja/newbs_flashing.md index 3e1529706e63..39f5da88a85d 100644 --- a/docs/ja/newbs_flashing.md +++ b/docs/ja/newbs_flashing.md @@ -1,12 +1,12 @@ -# ファームウェアを書きこむ +# ファームウェアを書き込む -カスタムファームウェアは出来たので、キーボードに書き込みたくなるでしょう/フラッシュしたくなるでしょう。 +カスタムファームウェアは出来たので、いよいよキーボードへの書き込み(フラッシュ)です。 ## キーボードを DFU (Bootloader) モードにする @@ -50,18 +50,22 @@ Finder またはエクスプローラーでファームウェアのファイル Windows か macOS を使用している場合、現在のフォルダをエクスプローラーか Finder で簡単に開くためのコマンドがあります。 -#### Windows + + +#### ** Windows ** ``` start . ``` -#### macOS +#### ** macOS ** ``` open . ``` + + ファームウェアファイルは常に以下の命名形式に従っています: ``` @@ -117,11 +121,13 @@ QMK Toolbox の `Flash` ボタンをクリックします。次のような出 WARNING: This board's bootloader is not specified or is not supported by the ":flash" target at this time. -この場合、あなたは明示的にブートローダを指定する方法を使わなければなりません。詳細は、[ファームウェアのフラッシュ](ja/flashing.md) ガイドを参照してください。 +この場合、あなたは明示的にブートローダを指定する方法を使わなければなりません。詳細は、[ファームウェアのフラッシュ](ja/flashing.md)ガイドを参照してください。 ## テストしましょう! -おめでとうございます! カスタムファームウェアがキーボードにプログラムされました! +おめでとうございます!カスタムファームウェアがキーボードにプログラムされ、テストする準備ができました! + +少し運が良ければ全てが完璧に機能しますが、そうでない場合は何が問題なのかを理解するのに役立つ手順があります。 +通常、キーボードのテストは非常に簡単です。全てのキーをひとつずつ押して、期待するキーが送信されることを確認します。例え QMK で動作していない場合でも、[QMK Configurator](https://config.qmk.fm/#/test/) のテストモードを使用すると、キーボードをチェックできます。 -使ってみて、すべてがあなたの望むように動作するかどうか確認してください。 -この初心者ガイドを完全なものにするために [テストとデバッグ](ja/newbs_testing_debugging.md) を書いたので、ファームウェアの検証とカスタム機能のトラブルシューティング方法について学ぶには、こちらをご覧ください。 +まだ動作しませんか?詳細については FAQ トピックを参照するか、[Discord でチャット](https://discord.gg/Uq7gcHh)してください。 diff --git a/docs/ja/newbs_learn_more_resources.md b/docs/ja/newbs_learn_more_resources.md index e5437ca86af1..686b92446518 100644 --- a/docs/ja/newbs_learn_more_resources.md +++ b/docs/ja/newbs_learn_more_resources.md @@ -2,13 +2,13 @@ これらのリソースは、QMK コミュニティの新しいメンバーに、初心者向けドキュメントで提供されている情報に対する理解を深めることを目的としています。 -## QMK に関するリソース: +## QMK に関するリソース ### 英語 :id=english-resources-qmk @@ -18,17 +18,35 @@ _日本語のリソース情報を募集中です。_ -## コマンドラインに関するリソース: +## コマンドラインに関するリソース :id=command-line-resources ### 英語 :id=english-resources-cli * [Good General Tutorial on Command Line](https://www.codecademy.com/learn/learn-the-command-line) +* [Must Know Linux Commands](https://www.guru99.com/must-know-linux-commands.html)
+* [Some Basic Unix Commands](https://www.tjhsst.edu/~dhyatt/superap/unixcmd.html) ### 日本語 :id=japanese-resources-cli _日本語のリソース情報を募集中です。_ -## Git に関するリソース: +## テキストエディタに関するリソース :id=text-editor-resources + +どのテキストエディタを使えば良いか分かりませんか? + +### 英語 :id=english-resources-text-editor + +* [a great introduction to the subject](https://learntocodewith.me/programming/basics/text-editors/) + +### 日本語 :id=japanese-resources-text-editor + +_日本語のリソース情報を募集中です。_ + +コーディング用に特別に作成されたエディタ: +* [Sublime Text](https://www.sublimetext.com/) +* [VS Code](https://code.visualstudio.com/) + +## Git に関するリソース ### 英語 :id=english-resources-git diff --git a/docs/ja/tap_hold.md b/docs/ja/tap_hold.md index bf23ae4ab0a2..07242821a998 100644 --- a/docs/ja/tap_hold.md +++ b/docs/ja/tap_hold.md @@ -1,8 +1,8 @@ # タップホールド設定オプション タップホールドオプションは素晴らしいものですが、問題が無いわけではありません。デフォルト設定を適切なものにしようとしましたが、一部の人にとってまだ問題を引き起こすかもしれません。 @@ -92,7 +92,7 @@ bool get_permissive_hold(uint16_t keycode, keyrecord_t *record) { #define IGNORE_MOD_TAP_INTERRUPT ``` -許容ホールドと同様に、これは高速なタイピストのためのファームウェアの処理方法を変更します。モッドタップキーを押し、他のキーを押し、モッドタップキーを放し、通常のキーを放すと、通常は両方のキーのタッピング機能が出力されます。これはローリングコンボキーには望ましくないかもしれません。 +許容ホールドと同様に、これは高速なタイピストのためのファームウェアの処理方法を変更します。モッドタップキーを押し、他のキーを押し、モッドタップキーを放し、通常のキーを放すと、`TAPPING_TERM` 内で押された場合でも、通常はモッドと通常のキーが出力されます。これは、ローリングコンボキーや、頻繁に使用するキー(例えば、`RCTL_T(KC_QUOT)`)にモッドタップを使う高速なタイピストには望ましくない場合があります。 `モッドタップ割り込みの無視`を設定するには、両方のキーを `TAPPING_TERM` の間ホールドすると、(その修飾キーの)ホールド機能を実行する必要があります。 @@ -103,7 +103,7 @@ bool get_permissive_hold(uint16_t keycode, keyrecord_t *record) { - `SFT_T(KC_A)` を放す - `KC_X` を放す -通常、これは `X` (`SHIFT`+`x`) を送信します。`モッドタップ割り込みの無視` を有効にすると、ホールドアクションを登録するには、両方のキーを `TAPPING_TERM` の間ホールドする必要があります。この場合、素早いタップは `ax` を送信しますが、両方をホールドすると、`X` (`SHIFT`+`x`) を出力します。 +通常、これは大文字の `X` (`SHIFT`+`x`)、またはモッド + キーを送信します。`モッドタップ割り込みの無視` を有効にすると、ホールドアクションを登録するには、両方のキーを `TAPPING_TERM` の間ホールドする必要があります。この場合、素早いタップは `ax` を送信しますが、両方をホールドすると、大文字の `X` (`SHIFT`+`x`) を出力します。 ?> __注意__: これはモディファイアにのみ関係し、レイヤー切り替えキーには関係しません。 @@ -137,8 +137,7 @@ bool get_ignore_mod_tap_interrupt(uint16_t keycode, keyrecord_t *record) { #define TAPPING_FORCE_HOLD ``` -タップの後でユーザがキーをホールドすると、ホールド機能がアクティブになるのではなく、デフォルトでタッピング機能が繰り返されます。これにより、デュアルロールキーのタッピング機能を自動繰り返しする機能を維持することができます。 -`TAPPING_FORCE_HOLD` は、デュアルロールキーをタップした後ホールドした場合、ユーザがホールド機能をアクティブにする機能を削除します。 +タップの後でユーザがキーをホールドすると、ホールド機能がアクティブになるのではなく、デフォルトでタッピング機能が繰り返されます。これにより、デュアルロールキーのタッピング機能を自動繰り返しする機能を維持することができます。`TAPPING_FORCE_HOLD` は、デュアルロールキーをタップした後ホールドした場合、ユーザがホールド機能をアクティブにする機能を削除します。 例: @@ -185,6 +184,25 @@ bool get_tapping_force_hold(uint16_t keycode, keyrecord_t *record) { 例えば、他のキーを押すことなく `LT(2, KC_SPACE)` を押したり放したりしても何も起こりません。これを有効にすると、代わりに `KC_SPACE` を送信します。 +この機能をより細かく制御するために、以下を `config.h` に追加することができます: + +```c +#define RETRO_TAPPING_PER_KEY +``` + +そして、以下の関数をキーマップに追加します: + +```c +bool get_retro_tapping(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case LT(2, KC_SPACE): + return true; + default: + return false; + } +} +``` + ## キー別の関数にキーレコードを含めるのはなぜですか? 「キー別」の関数全てにキーレコードを含んでいることに気付いたかもしれません。そしてなぜそうしたのか不思議に思っているかもしれません。 diff --git a/docs/one_shot_keys.md b/docs/one_shot_keys.md index 9fc5486299d9..f1f93199c28f 100644 --- a/docs/one_shot_keys.md +++ b/docs/one_shot_keys.md @@ -23,7 +23,7 @@ You can control the behavior of one shot keys by defining these in `config.h`: Sometimes, you want to activate a one-shot key as part of a macro or tap dance routine. -For one shot layers, you need to call `set_oneshot_layer(LAYER, ONESHOT_START)` on key down, and `clear_oneshot_layer_state(ONESHOT_OTHER_KEY_PRESSED)` on key up. If you want to cancel the oneshot, call `reset_oneshot_layer()`. +For one shot layers, you need to call `set_oneshot_layer(LAYER, ONESHOT_START)` on key down, and `clear_oneshot_layer_state(ONESHOT_PRESSED)` on key up. If you want to cancel the oneshot, call `reset_oneshot_layer()`. For one shot mods, you need to call `set_oneshot_mods(MOD_BIT(KC_*))` to set it, or `clear_oneshot_mods()` to cancel it. diff --git a/drivers/oled/oled_driver.c b/drivers/oled/oled_driver.c index 082115d53434..8e5ed5f070ef 100644 --- a/drivers/oled/oled_driver.c +++ b/drivers/oled/oled_driver.c @@ -115,7 +115,7 @@ bool oled_initialized = false; bool oled_active = false; bool oled_scrolling = false; uint8_t oled_brightness = OLED_BRIGHTNESS; -uint8_t oled_rotation = 0; +oled_rotation_t oled_rotation = 0; uint8_t oled_rotation_width = 0; uint8_t oled_scroll_speed = 0; // this holds the speed after being remapped to ssd1306 internal values uint8_t oled_scroll_start = 0; @@ -158,7 +158,7 @@ static void InvertCharacter(uint8_t *cursor) { } } -bool oled_init(uint8_t rotation) { +bool oled_init(oled_rotation_t rotation) { #if defined(USE_I2C) && defined(SPLIT_KEYBOARD) if (!is_keyboard_master()) { return true; @@ -491,8 +491,9 @@ void oled_write_raw(const char *data, uint16_t size) { uint16_t cursor_start_index = oled_cursor - &oled_buffer[0]; if ((size + cursor_start_index) > OLED_MATRIX_SIZE) size = OLED_MATRIX_SIZE - cursor_start_index; for (uint16_t i = cursor_start_index; i < cursor_start_index + size; i++) { - if (oled_buffer[i] == data[i]) continue; - oled_buffer[i] = data[i]; + uint8_t c = *data++; + if (oled_buffer[i] == c) continue; + oled_buffer[i] = c; oled_dirty |= ((OLED_BLOCK_TYPE)1 << (i / OLED_BLOCK_SIZE)); } } diff --git a/drivers/oled/oled_driver.h b/drivers/oled/oled_driver.h index cbf5380ee089..a6b85f37e6bb 100644 --- a/drivers/oled/oled_driver.h +++ b/drivers/oled/oled_driver.h @@ -226,13 +226,17 @@ void oled_write(const char *data, bool invert); void oled_write_ln(const char *data, bool invert); // Pans the buffer to the right (or left by passing true) by moving contents of the buffer +// Useful for moving the screen in preparation for new drawing void oled_pan(bool left); // Returns a pointer to the requested start index in the buffer plus remaining // buffer length as struct oled_buffer_reader_t oled_read_raw(uint16_t start_index); +// Writes a string to the buffer at current cursor position void oled_write_raw(const char *data, uint16_t size); + +// Writes a single byte into the buffer at the specified index void oled_write_raw_byte(const char data, uint16_t index); // Sets a specific pixel on or off @@ -251,17 +255,11 @@ void oled_write_P(const char *data, bool invert); // Remapped to call 'void oled_write_ln(const char *data, bool invert);' on ARM void oled_write_ln_P(const char *data, bool invert); +// Writes a PROGMEM string to the buffer at current cursor position void oled_write_raw_P(const char *data, uint16_t size); #else -// Writes a string to the buffer at current cursor position -// Advances the cursor while writing, inverts the pixels if true # define oled_write_P(data, invert) oled_write(data, invert) - -// Writes a string to the buffer at current cursor position -// Advances the cursor while writing, inverts the pixels if true -// Advances the cursor to the next page, wiring ' ' to the remainder of the current page # define oled_write_ln_P(data, invert) oled_write(data, invert) - # define oled_write_raw_P(data, size) oled_write_raw(data, size) #endif // defined(__AVR__) diff --git a/keyboards/anavi/macropad2/keymaps/binary/keymap.c b/keyboards/anavi/macropad2/keymaps/binary/keymap.c new file mode 100644 index 000000000000..366fcb1868fa --- /dev/null +++ b/keyboards/anavi/macropad2/keymaps/binary/keymap.c @@ -0,0 +1,30 @@ +/* Copyright 2021 Leon Anavi + * + * 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_0, KC_1 + ) +}; + +const uint16_t PROGMEM test_combo[] = {KC_0, KC_1, COMBO_END}; +combo_t key_combos[COMBO_COUNT] = {COMBO_ACTION(test_combo)}; + +void process_combo_event(uint16_t combo_index, bool pressed) { + backlight_step(); +} diff --git a/keyboards/anavi/macropad2/keymaps/binary/rules.mk b/keyboards/anavi/macropad2/keymaps/binary/rules.mk new file mode 100644 index 000000000000..ab1e438182a3 --- /dev/null +++ b/keyboards/anavi/macropad2/keymaps/binary/rules.mk @@ -0,0 +1 @@ +COMBO_ENABLE = yes diff --git a/keyboards/anavi/macropad2/keymaps/skype/keymap.c b/keyboards/anavi/macropad2/keymaps/skype/keymap.c new file mode 100644 index 000000000000..b05137edeff8 --- /dev/null +++ b/keyboards/anavi/macropad2/keymaps/skype/keymap.c @@ -0,0 +1,41 @@ +/* Copyright 2021 Leon Anavi + * + * 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 + +/* + * The keymap contains the following shortcuts for Skype on + * MS Windows and GNU/Linux distributions: + * + * Ctrl+M: Mute/unmute microphone + * Ctrl+Shift+K: Start/stop camera + * + * NOTE: Mac users should change the shortcut to toggle the mic + * to Command+Shift+M, for example KC_LGUI(LSFT(KC_M)) + */ + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT( + LCTL(KC_M), LCTL(LSFT(KC_K)) + ) +}; + +const uint16_t PROGMEM test_combo[] = {LCTL(KC_M), LCTL(LSFT(KC_K)), COMBO_END}; +combo_t key_combos[COMBO_COUNT] = {COMBO_ACTION(test_combo)}; + +void process_combo_event(uint16_t combo_index, bool pressed) { + backlight_step(); +} diff --git a/keyboards/anavi/macropad2/keymaps/skype/rules.mk b/keyboards/anavi/macropad2/keymaps/skype/rules.mk new file mode 100644 index 000000000000..ab1e438182a3 --- /dev/null +++ b/keyboards/anavi/macropad2/keymaps/skype/rules.mk @@ -0,0 +1 @@ +COMBO_ENABLE = yes diff --git a/keyboards/babyv/keymaps/melonbred/keymap.c b/keyboards/babyv/keymaps/melonbred/keymap.c new file mode 100644 index 000000000000..ea62241e9d8e --- /dev/null +++ b/keyboards/babyv/keymaps/melonbred/keymap.c @@ -0,0 +1,62 @@ +/* Copyright 2020 melonbred + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + LAYER0, + LAYER1, + LAYER2, +}; + + +// Tap Dance Declarations +enum { + TD_M_D = 0, + TD_P_M +}; + +// Tap Dance Definition +qk_tap_dance_action_t tap_dance_actions[] = { + //Tap once for minus, tap twice for divide + [TD_M_D] = ACTION_TAP_DANCE_DOUBLE(KC_PMNS, KC_PSLS), + //Tap once for plus, tap twice for multiply + [TD_P_M] = ACTION_TAP_DANCE_DOUBLE(KC_PPLS, KC_PAST) +}; + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [LAYER0] = LAYOUT_2u( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + CTL_T(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_SLSH, KC_RSFT, + MO(LAYER2), KC_LALT, LT(LAYER1, KC_SPC), KC_SPC, KC_RALT, KC_LGUI + ), + + [LAYER1] = LAYOUT_2u( + KC_GRV, KC_QUOT, _______, KC_UP, _______, _______, KC_7, KC_8, KC_9, KC_PMNS, KC_PSLS, KC_DEL, + KC_CAPS, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, KC_4, KC_5, KC_6, KC_PPLS, KC_PAST, KC_ENT, + KC_LSFT, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, KC_1, KC_2, KC_3, XXXXXXX, XXXXXXX, KC_RSFT, + XXXXXXX, _______, _______, KC_0, KC_PDOT, _______ + ), + + [LAYER2] = LAYOUT_2u( + 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_VOLU, KC_MPLY, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, + KC_VOLD, KC_MUTE, XXXXXXX, XXXXXXX, XXXXXXX, RESET, XXXXXXX, XXXXXXX, KC_RCTL, KC_RALT, KC_DEL, XXXXXXX, + _______, KC_NLCK, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX + ), +}; diff --git a/keyboards/bm40hsrgb/config.h b/keyboards/bm40hsrgb/config.h index 84d0950d59e1..167a5667a441 100755 --- a/keyboards/bm40hsrgb/config.h +++ b/keyboards/bm40hsrgb/config.h @@ -50,6 +50,6 @@ #ifdef RGB_DI_PIN #define RGB_MATRIX_KEYPRESSES // reacts to keypresses #endif -#ifdef RGB_MATRIX_ENABLE +#ifndef RGB_DISABLE_WHEN_USB_SUSPENDED # define RGB_DISABLE_WHEN_USB_SUSPENDED true // turn off effects when suspended #endif diff --git a/keyboards/bm60rgb/bm60rgb.h b/keyboards/bm60rgb/bm60rgb.h index 705539fc95d8..4a3dc2e83d59 100644 --- a/keyboards/bm60rgb/bm60rgb.h +++ b/keyboards/bm60rgb/bm60rgb.h @@ -17,7 +17,7 @@ #include "quantum.h" -#define LAYOUT( \ +#define LAYOUT_60_ansi_arrow( \ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \ K20, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, \ diff --git a/keyboards/bm60rgb/info.json b/keyboards/bm60rgb/info.json index 5871bd5bcaaf..d467a0405d1c 100644 --- a/keyboards/bm60rgb/info.json +++ b/keyboards/bm60rgb/info.json @@ -4,9 +4,11 @@ "maintainer": "qmk", "width": 15, "height": 5, + "layout_aliases": { + "LAYOUT": "LAYOUT_60_ansi_arrow" + }, "layouts": { - "LAYOUT_60_iso_arrow": { - "key_count": 63, + "LAYOUT_60_ansi_arrow": { "layout": [ {"label":"K00 (B0,D0)", "x":0, "y":0}, {"label":"K01 (B0,D1)", "x":1, "y":0}, diff --git a/keyboards/bm60rgb/keymaps/default/keymap.c b/keyboards/bm60rgb/keymaps/default/keymap.c index 9099a0407343..e8be1cccf681 100644 --- a/keyboards/bm60rgb/keymaps/default/keymap.c +++ b/keyboards/bm60rgb/keymaps/default/keymap.c @@ -16,14 +16,14 @@ #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { - [0] = LAYOUT( + [0] = LAYOUT_60_ansi_arrow( 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_RSFT, KC_UP, KC_SLSH, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT ), - [1] = LAYOUT( + [1] = LAYOUT_60_ansi_arrow( RESET, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, _______, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, diff --git a/keyboards/bm60rgb/keymaps/via/keymap.c b/keyboards/bm60rgb/keymaps/via/keymap.c index d84aaf5256d0..da2f6e8cedf5 100644 --- a/keyboards/bm60rgb/keymaps/via/keymap.c +++ b/keyboards/bm60rgb/keymaps/via/keymap.c @@ -16,28 +16,28 @@ #include QMK_KEYBOARD_H const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { - [0] = LAYOUT( + [0] = LAYOUT_60_ansi_arrow( 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_RSFT, KC_UP, KC_SLSH, KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT ), - [1] = LAYOUT( + [1] = LAYOUT_60_ansi_arrow( RESET, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, _______, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), - [2] = LAYOUT( + [2] = LAYOUT_60_ansi_arrow( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ), - [3] = LAYOUT( + [3] = LAYOUT_60_ansi_arrow( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, diff --git a/keyboards/bm60rgb/rules.mk b/keyboards/bm60rgb/rules.mk index bf1b1ffa4d75..49f18fcbffd8 100644 --- a/keyboards/bm60rgb/rules.mk +++ b/keyboards/bm60rgb/rules.mk @@ -33,5 +33,7 @@ RGB_MATRIX_ENABLE = yes RGB_MATRIX_DRIVER = WS2812 LTO_ENABLE = yes +LAYOUTS = 60_ansi_arrow + # partially generated by KBFirmware JSON to QMK Parser # https://noroadsleft.github.io/kbf_qmk_converter/ diff --git a/keyboards/buildakb/potato65hs/potato65hs.h b/keyboards/buildakb/potato65hs/potato65hs.h index 96884bc5284e..5f7b9cbf1926 100644 --- a/keyboards/buildakb/potato65hs/potato65hs.h +++ b/keyboards/buildakb/potato65hs/potato65hs.h @@ -22,12 +22,12 @@ K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014, \ K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114, \ K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K213, K214, \ - K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K313, K314, \ + K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K313, K314, \ K400, K401, K402, K403, K409, K410, K411, K413, K414 \ ) { \ { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014 }, \ { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114 }, \ { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, KC_NO, K213, K214 }, \ - { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, KC_NO, K311, K313, K314 }, \ + { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, KC_NO, K313, K314 }, \ { K400, K401, K402, K403, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, K409, K410, KC_NO, K411, K413, K414 } \ } diff --git a/keyboards/clawsome/hatchback/config.h b/keyboards/clawsome/hatchback/config.h new file mode 100644 index 000000000000..6560ad154f1b --- /dev/null +++ b/keyboards/clawsome/hatchback/config.h @@ -0,0 +1,45 @@ +/* Copyright 2021 AAClawson (AlisGraveNil) + * + * 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 "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x7767 +#define PRODUCT_ID 0x0000 +#define DEVICE_VER 0x0001 +#define MANUFACTURER AlisGraveNil +#define PRODUCT hatchbackTKL + +/* key matrix size */ +#define MATRIX_ROWS 12 +#define MATRIX_COLS 10 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { B0, B6, D4, B4, D0, B5, D1, E6, D2, D7, D3, C6 } +#define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3, B2, D5, C7, F1 } + +#define DIODE_DIRECTION COL2ROW diff --git a/keyboards/clawsome/hatchback/hatcback.h b/keyboards/clawsome/hatchback/hatcback.h new file mode 100644 index 000000000000..b30eda09f478 --- /dev/null +++ b/keyboards/clawsome/hatchback/hatcback.h @@ -0,0 +1,41 @@ +/* Copyright 2021 AAClawson (AlisGraveNil) + * + * 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, K01, K11, K02, K12, K03, K13, K04, K14, K05, K15, K06, K16, K07, K18, K09, \ + K20, K30, K21, K31, K22, K32, K23, K33, K24, K34, K25, K35, K26, K36, K27, K38, K29, \ + K40, K50, K41, K51, K42, K52, K43, K53, K44, K54, K45, K55, K46, K56, K47, K58, K49, \ + K60, K70, K61, K71, K62, K72, K63, K73, K64, K74, K65, K75, K76, \ + K80, K90, K81, K91, K82, K92, K83, K93, K84, K94, K85, K96, K98, \ + KA0, KB0, KA1, KA2, KA3, KA4, KA5, KB5, KA6, KB6, KA7, KB8, KA9 \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07, KC_NO, K09 }, \ + { KC_NO, K11, K12, K13, K14, K15, K16, KC_NO, K18, KC_NO }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, KC_NO, K29 }, \ + { K30, K31, K32, K33, K34, K35, K36, KC_NO, K38, KC_NO }, \ + { K40, K41, K42, K43, K44, K45, K46, K47, KC_NO, K49 }, \ + { K50, K51, K52, K53, K54, K55, K56, KC_NO, K58, KC_NO }, \ + { K60, K61, K62, K63, K64, K65, KC_NO, KC_NO, KC_NO, KC_NO }, \ + { K70, K71, K72, K73, K74, K75, K76, KC_NO, KC_NO, KC_NO }, \ + { K80, K81, K82, K83, K84, K85, KC_NO, KC_NO, KC_NO, KC_NO }, \ + { K90, K91, K92, K93, K94, KC_NO, K96, KC_NO, K98, KC_NO }, \ + { KA0, KA1, KA2, KA3, KA4, KA5, KA6, KA7, KC_NO, KA9 }, \ + { KB0, KC_NO, KC_NO, KC_NO, KC_NO, KB5, KB6, KC_NO, KB8, KC_NO }, \ +} diff --git a/keyboards/clawsome/hatchback/hatchback.c b/keyboards/clawsome/hatchback/hatchback.c new file mode 100644 index 000000000000..117593a68899 --- /dev/null +++ b/keyboards/clawsome/hatchback/hatchback.c @@ -0,0 +1,17 @@ +/* Copyright 2021 AAClawson (AlisGraveNil) + * + * 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 "hatchback.h" diff --git a/keyboards/clawsome/hatchback/info.json b/keyboards/clawsome/hatchback/info.json new file mode 100644 index 000000000000..f3d750607d39 --- /dev/null +++ b/keyboards/clawsome/hatchback/info.json @@ -0,0 +1,102 @@ +{ + "keyboard_name": "hatchbackTKL", + "url": "www.clawboards.xyz", + "maintainer": "AAClawson (AlisGraveNil)", + "width": 18.25, + "height": 6.5, + "layouts": { + "LAYOUT": { + "layout": [ + {"label":"K00 (B0,F4)", "x":0, "y":0}, + {"label":"K01 (B0,F5)", "x":2, "y":0}, + {"label":"K11 (B6,F5)", "x":3, "y":0}, + {"label":"K02 (B0,F6)", "x":4, "y":0}, + {"label":"K12 (B6,F6)", "x":5, "y":0}, + {"label":"K03 (B0,F7)", "x":6.5, "y":0}, + {"label":"K13 (B6,F7)", "x":7.5, "y":0}, + {"label":"K04 (B0,B1)", "x":8.5, "y":0}, + {"label":"K14 (B6,B1)", "x":9.5, "y":0}, + {"label":"K05 (B0,B3)", "x":11, "y":0}, + {"label":"K15 (B6,B3)", "x":12, "y":0}, + {"label":"K06 (B0,B2)", "x":13, "y":0}, + {"label":"K16 (B6,B2)", "x":14, "y":0}, + {"label":"K07 (B0,D5)", "x":15.25, "y":0}, + {"label":"K18 (B6,C7)", "x":16.25, "y":0}, + {"label":"K09 (B0,F1)", "x":17.25, "y":0}, + {"label":"K20 (D4,F4)", "x":0, "y":1.5}, + {"label":"K30 (B4,F4)", "x":1, "y":1.5}, + {"label":"K21 (D4,F5)", "x":2, "y":1.5}, + {"label":"K31 (B4,F5)", "x":3, "y":1.5}, + {"label":"K22 (D4,F6)", "x":4, "y":1.5}, + {"label":"K32 (B4,F6)", "x":5, "y":1.5}, + {"label":"K23 (D4,F7)", "x":6, "y":1.5}, + {"label":"K33 (B4,F7)", "x":7, "y":1.5}, + {"label":"K24 (D4,B1)", "x":8, "y":1.5}, + {"label":"K34 (B4,B1)", "x":9, "y":1.5}, + {"label":"K25 (D4,B3)", "x":10, "y":1.5}, + {"label":"K35 (B4,B3)", "x":11, "y":1.5}, + {"label":"K26 (D4,B2)", "x":12, "y":1.5}, + {"label":"K36 (B4,B2)", "x":13, "y":1.5, "w":2}, + {"label":"K27 (D4,D5)", "x":15.25, "y":1.5}, + {"label":"K38 (B4,C7)", "x":16.25, "y":1.5}, + {"label":"K29 (D4,F1)", "x":17.25, "y":1.5}, + {"label":"K40 (D0,F4)", "x":0, "y":2.5, "w":1.5}, + {"label":"K50 (B5,F4)", "x":1.5, "y":2.5}, + {"label":"K41 (D0,F5)", "x":2.5, "y":2.5}, + {"label":"K51 (B5,F5)", "x":3.5, "y":2.5}, + {"label":"K42 (D0,F6)", "x":4.5, "y":2.5}, + {"label":"K52 (B5,F6)", "x":5.5, "y":2.5}, + {"label":"K43 (D0,F7)", "x":6.5, "y":2.5}, + {"label":"K53 (B5,F7)", "x":7.5, "y":2.5}, + {"label":"K44 (D0,B1)", "x":8.5, "y":2.5}, + {"label":"K54 (B5,B1)", "x":9.5, "y":2.5}, + {"label":"K45 (D0,B3)", "x":10.5, "y":2.5}, + {"label":"K55 (B5,B3)", "x":11.5, "y":2.5}, + {"label":"K46 (D0,B2)", "x":12.5, "y":2.5}, + {"label":"K56 (B5,B2)", "x":13.5, "y":2.5, "w":1.5}, + {"label":"K47 (D0,D5)", "x":15.25, "y":2.5}, + {"label":"K58 (B5,C7)", "x":16.25, "y":2.5}, + {"label":"K49 (D0,F1)", "x":17.25, "y":2.5}, + {"label":"K60 (D1,F4)", "x":0, "y":3.5, "w":1.75}, + {"label":"K70 (E6,F4)", "x":1.75, "y":3.5}, + {"label":"K61 (D1,F5)", "x":2.75, "y":3.5}, + {"label":"K71 (E6,F5)", "x":3.75, "y":3.5}, + {"label":"K62 (D1,F6)", "x":4.75, "y":3.5}, + {"label":"K72 (E6,F6)", "x":5.75, "y":3.5}, + {"label":"K63 (D1,F7)", "x":6.75, "y":3.5}, + {"label":"K73 (E6,F7)", "x":7.75, "y":3.5}, + {"label":"K64 (D1,B1)", "x":8.75, "y":3.5}, + {"label":"K74 (E6,B1)", "x":9.75, "y":3.5}, + {"label":"K65 (D1,B3)", "x":10.75, "y":3.5}, + {"label":"K75 (E6,B3)", "x":11.75, "y":3.5}, + {"label":"K76 (E6,B2)", "x":12.75, "y":3.5, "w":2.25}, + {"label":"K80 (D2,F4)", "x":0, "y":4.5, "w":2.25}, + {"label":"K90 (D7,F4)", "x":2.25, "y":4.5}, + {"label":"K81 (D2,F5)", "x":3.25, "y":4.5}, + {"label":"K91 (D7,F5)", "x":4.25, "y":4.5}, + {"label":"K82 (D2,F6)", "x":5.25, "y":4.5}, + {"label":"K92 (D7,F6)", "x":6.25, "y":4.5}, + {"label":"K83 (D2,F7)", "x":7.25, "y":4.5}, + {"label":"K93 (D7,F7)", "x":8.25, "y":4.5}, + {"label":"K84 (D2,B1)", "x":9.25, "y":4.5}, + {"label":"K94 (D7,B1)", "x":10.25, "y":4.5}, + {"label":"K85 (D2,B3)", "x":11.25, "y":4.5}, + {"label":"K96 (D7,B2)", "x":12.25, "y":4.5, "w":2.75}, + {"label":"K98 (D7,C7)", "x":16.25, "y":4.5}, + {"label":"KA0 (D3,F4)", "x":0, "y":5.5, "w":1.25}, + {"label":"KB0 (C6,F4)", "x":1.25, "y":5.5, "w":1.25}, + {"label":"KA1 (D3,F5)", "x":2.5, "y":5.5, "w":1.25}, + {"label":"KA2 (D3,F6)", "x":3.75, "y":5.5, "w":2.25}, + {"label":"KA3 (D3,F7)", "x":6, "y":5.5, "w":1.75}, + {"label":"KA4 (D3,B1)", "x":7.75, "y":5.5, "w":2.25}, + {"label":"KA5 (D3,B3)", "x":10, "y":5.5, "w":1.25}, + {"label":"KB5 (C6,B3)", "x":11.25, "y":5.5, "w":1.25}, + {"label":"KA6 (D3,B2)", "x":12.5, "y":5.5, "w":1.25}, + {"label":"KB6 (C6,B2)", "x":13.75, "y":5.5, "w":1.25}, + {"label":"KA7 (D3,D5)", "x":15.25, "y":5.5}, + {"label":"KB8 (C6,C7)", "x":16.25, "y":5.5}, + {"label":"KA9 (D3,F1)", "x":17.25, "y":5.5} + ] + } + } +} diff --git a/keyboards/clawsome/hatchback/keymap/default/keymap.c b/keyboards/clawsome/hatchback/keymap/default/keymap.c new file mode 100644 index 000000000000..279666e06cc1 --- /dev/null +++ b/keyboards/clawsome/hatchback/keymap/default/keymap.c @@ -0,0 +1,30 @@ +/* Copyright 2021 AAClawson (AlisGraveNil) + * + * 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_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_SLCK, 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_SPC, KC_SPC, KC_RALT, KC_RGUI, KC_MENU, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + +}; + diff --git a/keyboards/clawsome/hatchback/readme.md b/keyboards/clawsome/hatchback/readme.md new file mode 100644 index 000000000000..2a680288bf3c --- /dev/null +++ b/keyboards/clawsome/hatchback/readme.md @@ -0,0 +1,14 @@ +# SUV + +This is TKL keyboard that can be converted down into a 75% keyboard and a 13key macropad (see "luggage rack") + +- Keyboard Maintainer: [AAClawson](https://github.com/AlisGraveNil) +- Hardware Supported: Hatchback, Elite-C (as TKL); Pro-Micro and nice!nano (as 75%) +- Hardware Availability: In stock within the next month + +Make example for this keyboard (after setting up your build environment): + + make clawsome/hatchback:default + Connect your board to your computer; connect the "GND" and "RST" pins on your controller using a wire or a pair of tweezers and hold it for 3 seconds to force the controller into bootloader mode. Then use QMK Toolbox to flash the .hex you downloaded from the QMK website. If using an Elite-C, there's a small black reset button on the PCB you can press instead of trying to connect the two pins. + +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/clawsome/hatchback/rules.mk b/keyboards/clawsome/hatchback/rules.mk new file mode 100644 index 000000000000..6b8d1b5f071c --- /dev/null +++ b/keyboards/clawsome/hatchback/rules.mk @@ -0,0 +1,22 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = caterina + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = yes # Console for debug +COMMAND_ENABLE = yes # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = no # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output diff --git a/keyboards/clawsome/suv/config.h b/keyboards/clawsome/suv/config.h new file mode 100644 index 000000000000..8ea2ed5bdcea --- /dev/null +++ b/keyboards/clawsome/suv/config.h @@ -0,0 +1,45 @@ +/* Copyright 2021 AAClawson (AlisGraveNil) + * + * 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 "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x7767 +#define PRODUCT_ID 0x0000 +#define DEVICE_VER 0x0001 +#define MANUFACTURER AlisGraveNil +#define PRODUCT suv1.1 + +/* key matrix size */ +#define MATRIX_ROWS 12 +#define MATRIX_COLS 11 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { F0, B6, D0, F6, D4, F7, B3, B1, B0, C6, B2, D7 } +#define MATRIX_COL_PINS { D3, D2, D1, B4, B5, B7, D5, C7, F1, F5, F4 } + +#define DIODE_DIRECTION COL2ROW diff --git a/keyboards/clawsome/suv/info.json b/keyboards/clawsome/suv/info.json new file mode 100644 index 000000000000..f44f6aa4447a --- /dev/null +++ b/keyboards/clawsome/suv/info.json @@ -0,0 +1,120 @@ +{ + "keyboard_name": "suv1.1", + "url": "www.clawboards.xyz", + "maintainer": "AAClawson (AlisGraveNil)", + "width": 22.5, + "height": 6.5, + "layouts": { + "LAYOUT": { + "layout": [ + {"label":"K00 (F0,D3)", "x":0, "y":0}, + {"label":"K01 (F0,D2)", "x":2, "y":0}, + {"label":"K11 (B6,D2)", "x":3, "y":0}, + {"label":"K02 (F0,D1)", "x":4, "y":0}, + {"label":"K12 (B6,D1)", "x":5, "y":0}, + {"label":"K03 (F0,B4)", "x":6.5, "y":0}, + {"label":"K13 (B6,B4)", "x":7.5, "y":0}, + {"label":"K04 (F0,B5)", "x":8.5, "y":0}, + {"label":"K14 (B6,B5)", "x":9.5, "y":0}, + {"label":"K05 (F0,B7)", "x":11, "y":0}, + {"label":"K15 (B6,B7)", "x":12, "y":0}, + {"label":"K06 (F0,D5)", "x":13, "y":0}, + {"label":"K16 (B6,D5)", "x":14, "y":0}, + {"label":"K07 (F0,C7)", "x":15.25, "y":0}, + {"label":"K17 (B6,C7)", "x":16.25, "y":0}, + {"label":"K08 (F0,F1)", "x":17.25, "y":0}, + {"label":"K20 (D0,D3)", "x":0, "y":1.5}, + {"label":"K30 (F6,D3)", "x":1, "y":1.5}, + {"label":"K21 (D0,D2)", "x":2, "y":1.5}, + {"label":"K31 (F6,D2)", "x":3, "y":1.5}, + {"label":"K22 (D0,D1)", "x":4, "y":1.5}, + {"label":"K32 (F6,D1)", "x":5, "y":1.5}, + {"label":"K23 (D0,B4)", "x":6, "y":1.5}, + {"label":"K33 (F6,B4)", "x":7, "y":1.5}, + {"label":"K24 (D0,B5)", "x":8, "y":1.5}, + {"label":"K34 (F6,B5)", "x":9, "y":1.5}, + {"label":"K25 (D0,B7)", "x":10, "y":1.5}, + {"label":"K35 (F6,B7)", "x":11, "y":1.5}, + {"label":"K26 (D0,D5)", "x":12, "y":1.5}, + {"label":"K36 (F6,D5)", "x":13, "y":1.5, "w":2}, + {"label":"K27 (D0,C7)", "x":15.25, "y":1.5}, + {"label":"K37 (F6,C7)", "x":16.25, "y":1.5}, + {"label":"K28 (D0,F1)", "x":17.25, "y":1.5}, + {"label":"K38 (F6,F1)", "x":18.5, "y":1.5}, + {"label":"K29 (D0,F5)", "x":19.5, "y":1.5}, + {"label":"K39 (F6,F5)", "x":20.5, "y":1.5}, + {"label":"K2A (D0,F4)", "x":21.5, "y":1.5}, + {"label":"K40 (D4,D3)", "x":0, "y":2.5, "w":1.5}, + {"label":"K50 (F7,D3)", "x":1.5, "y":2.5}, + {"label":"K41 (D4,D2)", "x":2.5, "y":2.5}, + {"label":"K51 (F7,D2)", "x":3.5, "y":2.5}, + {"label":"K42 (D4,D1)", "x":4.5, "y":2.5}, + {"label":"K52 (F7,D1)", "x":5.5, "y":2.5}, + {"label":"K43 (D4,B4)", "x":6.5, "y":2.5}, + {"label":"K53 (F7,B4)", "x":7.5, "y":2.5}, + {"label":"K44 (D4,B5)", "x":8.5, "y":2.5}, + {"label":"K54 (F7,B5)", "x":9.5, "y":2.5}, + {"label":"K45 (D4,B7)", "x":10.5, "y":2.5}, + {"label":"K55 (F7,B7)", "x":11.5, "y":2.5}, + {"label":"K46 (D4,D5)", "x":12.5, "y":2.5}, + {"label":"K56 (F7,D5)", "x":13.5, "y":2.5, "w":1.5}, + {"label":"K47 (D4,C7)", "x":15.25, "y":2.5}, + {"label":"K57 (F7,C7)", "x":16.25, "y":2.5}, + {"label":"K48 (D4,F1)", "x":17.25, "y":2.5}, + {"label":"K58 (F7,F1)", "x":18.5, "y":2.5}, + {"label":"K49 (D4,F5)", "x":19.5, "y":2.5}, + {"label":"K59 (F7,F5)", "x":20.5, "y":2.5}, + {"label":"K4A (D4,F4)", "x":21.5, "y":2.5, "h":2}, + {"label":"K60 (B3,D3)", "x":0, "y":3.5, "w":1.75}, + {"label":"K70 (B1,D3)", "x":1.75, "y":3.5}, + {"label":"K61 (B3,D2)", "x":2.75, "y":3.5}, + {"label":"K71 (B1,D2)", "x":3.75, "y":3.5}, + {"label":"K62 (B3,D1)", "x":4.75, "y":3.5}, + {"label":"K72 (B1,D1)", "x":5.75, "y":3.5}, + {"label":"K63 (B3,B4)", "x":6.75, "y":3.5}, + {"label":"K73 (B1,B4)", "x":7.75, "y":3.5}, + {"label":"K64 (B3,B5)", "x":8.75, "y":3.5}, + {"label":"K74 (B1,B5)", "x":9.75, "y":3.5}, + {"label":"K65 (B3,B7)", "x":10.75, "y":3.5}, + {"label":"K75 (B1,B7)", "x":11.75, "y":3.5}, + {"label":"K76 (B1,D5)", "x":12.75, "y":3.5, "w":2.25}, + {"label":"K78 (B1,F1)", "x":18.5, "y":3.5}, + {"label":"K69 (B3,F5)", "x":19.5, "y":3.5}, + {"label":"K79 (B1,F5)", "x":20.5, "y":3.5}, + {"label":"K80 (B0,D3)", "x":0, "y":4.5, "w":2.25}, + {"label":"K90 (C6,D3)", "x":2.25, "y":4.5}, + {"label":"K81 (B0,D2)", "x":3.25, "y":4.5}, + {"label":"K91 (C6,D2)", "x":4.25, "y":4.5}, + {"label":"K82 (B0,D1)", "x":5.25, "y":4.5}, + {"label":"K92 (C6,D1)", "x":6.25, "y":4.5}, + {"label":"K83 (B0,B4)", "x":7.25, "y":4.5}, + {"label":"K93 (C6,B4)", "x":8.25, "y":4.5}, + {"label":"K84 (B0,B5)", "x":9.25, "y":4.5}, + {"label":"K94 (C6,B5)", "x":10.25, "y":4.5}, + {"label":"K85 (B0,B7)", "x":11.25, "y":4.5}, + {"label":"K96 (C6,D5)", "x":12.25, "y":4.5, "w":2.75}, + {"label":"K97 (C6,C7)", "x":16.25, "y":4.5}, + {"label":"K98 (C6,F1)", "x":18.5, "y":4.5}, + {"label":"K89 (B0,F5)", "x":19.5, "y":4.5}, + {"label":"K99 (C6,F5)", "x":20.5, "y":4.5}, + {"label":"K8A (B0,F4)", "x":21.5, "y":4.5, "h":2}, + {"label":"KA0 (B2,D3)", "x":0, "y":5.5, "w":1.25}, + {"label":"KB0 (D7,D3)", "x":1.25, "y":5.5, "w":1.25}, + {"label":"KA1 (B2,D2)", "x":2.5, "y":5.5, "w":1.25}, + {"label":"KA2 (B2,D1)", "x":3.75, "y":5.5, "w":2.25}, + {"label":"KA3 (B2,B4)", "x":6, "y":5.5, "w":1.75}, + {"label":"KA4 (B2,B5)", "x":7.75, "y":5.5, "w":2.25}, + {"label":"KA5 (B2,B7)", "x":10, "y":5.5, "w":1.25}, + {"label":"KB5 (D7,B7)", "x":11.25, "y":5.5, "w":1.25}, + {"label":"KA6 (B2,D5)", "x":12.5, "y":5.5, "w":1.25}, + {"label":"KB6 (D7,D5)", "x":13.75, "y":5.5, "w":1.25}, + {"label":"KA7 (B2,C7)", "x":15.25, "y":5.5}, + {"label":"KB7 (D7,C7)", "x":16.25, "y":5.5}, + {"label":"KA8 (B2,F1)", "x":17.25, "y":5.5}, + {"label":"KB8 (D7,F1)", "x":18.5, "y":5.5, "w":2}, + {"label":"KB9 (D7,F5)", "x":20.5, "y":5.5} + ] + } + } +} + diff --git a/keyboards/clawsome/suv/keymap/default/keymap.c b/keyboards/clawsome/suv/keymap/default/keymap.c new file mode 100644 index 000000000000..b09cf08ddc0d --- /dev/null +++ b/keyboards/clawsome/suv/keymap/default/keymap.c @@ -0,0 +1,30 @@ +/* Copyright 2021 AAClawson (AlisGraveNil) + * + * 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_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_SLCK, 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_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, KC_P7, KC_P8, KC_P9, KC_PPLS, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_P4, KC_P5, KC_P6, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_LSFT, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_LALT, KC_LGUI, KC_MENU, KC_LCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT + ), + +}; + diff --git a/keyboards/clawsome/suv/readme.md b/keyboards/clawsome/suv/readme.md new file mode 100644 index 000000000000..1676a8dc78f3 --- /dev/null +++ b/keyboards/clawsome/suv/readme.md @@ -0,0 +1,13 @@ +# SUV + +This is 100% keyboard with the standard layout of a 104-key setup. + +- Keyboard Maintainer: [AAClawson](https://github.com/AlisGraveNil) +- Hardware Supported: SUV, Elite-C +- Hardware Availability: In stock within the next month + +Make example for this keyboard (after setting up your build environment): + + make clawsome/suv: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). diff --git a/keyboards/clawsome/suv/rules.mk b/keyboards/clawsome/suv/rules.mk new file mode 100644 index 000000000000..64d67049f9a6 --- /dev/null +++ b/keyboards/clawsome/suv/rules.mk @@ -0,0 +1,22 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = caterina + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = yes # Console for debug +COMMAND_ENABLE = yes # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = no # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output \ No newline at end of file diff --git a/keyboards/clawsome/suv/suv.c b/keyboards/clawsome/suv/suv.c new file mode 100644 index 000000000000..d456be885064 --- /dev/null +++ b/keyboards/clawsome/suv/suv.c @@ -0,0 +1,17 @@ +/* Copyright 2021 AAClawson (AlisGraveNil) + * + * 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 "suv.h" \ No newline at end of file diff --git a/keyboards/clawsome/suv/suv.h b/keyboards/clawsome/suv/suv.h new file mode 100644 index 000000000000..64ed0e7d0f47 --- /dev/null +++ b/keyboards/clawsome/suv/suv.h @@ -0,0 +1,41 @@ +/* Copyright 2021 AAClawson (AlisGraveNil) + * + * 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, K01, K11, K02, K12, K03, K13, K04, K14, K05, K15, K06, K16, K07, K17, K08, \ + K20, K30, K21, K31, K22, K32, K23, K33, K24, K34, K25, K35, K26, K36, K27, K37, K28, K38, K29, K39, K2A, \ + K40, K50, K41, K51, K42, K52, K43, K53, K44, K54, K45, K55, K46, K56, K47, K57, K48, K58, K49, K59, K4A, \ + K60, K70, K61, K71, K62, K72, K63, K73, K64, K74, K65, K75, K76, K78, K69, K79, \ + K80, K90, K81, K91, K82, K92, K83, K93, K84, K94, K85, K96, K97, K98, K89, K99, K8A, \ + KA0, KB0, KA1, KA2, KA3, KA4, KA5, KB5, KA6, KB6, KA7, KB7, KA8, KB8, KB9 \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, KC_NO, KC_NO }, \ + { KC_NO, K11, K12, K13, K14, K15, K16, K17, KC_NO, KC_NO, KC_NO }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A }, \ + { K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, KC_NO }, \ + { K40, K41, K42, K43, K44, K45, K46, K47, K48, K49, K4A }, \ + { K50, K51, K52, K53, K54, K55, K56, K57, K58, K59, KC_NO }, \ + { K60, K61, K62, K63, K64, K65, KC_NO, KC_NO, KC_NO, K69, KC_NO }, \ + { K70, K71, K72, K73, K74, K75, K76, KC_NO, K78, K79, KC_NO }, \ + { K80, K81, K82, K83, K84, K85, KC_NO, KC_NO, KC_NO, K89, K8A }, \ + { K90, K91, K92, K93, K94, KC_NO, K96, K97, K98, K99, KC_NO }, \ + { KA0, KA1, KA2, KA3, KA4, KA5, KA6, KA7, KA8, KC_NO, KC_NO }, \ + { KB0, KC_NO, KC_NO, KC_NO, KC_NO, KB5, KB6, KB7, KB8, KB9, KC_NO }, \ +} diff --git a/keyboards/dztech/dz65rgb/config.h b/keyboards/dztech/dz65rgb/config.h index b8c5759db6b6..71487efbd9d1 100644 --- a/keyboards/dztech/dz65rgb/config.h +++ b/keyboards/dztech/dz65rgb/config.h @@ -1,3 +1,18 @@ +/* Copyright 2021 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 "config_common.h" diff --git a/keyboards/dztech/dz65rgb/dz65rgb.c b/keyboards/dztech/dz65rgb/dz65rgb.c index aa5bf6601cde..8340d8fcee06 100644 --- a/keyboards/dztech/dz65rgb/dz65rgb.c +++ b/keyboards/dztech/dz65rgb/dz65rgb.c @@ -1,117 +1,17 @@ +/* Copyright 2021 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 "dz65rgb.h" - -#ifdef RGB_MATRIX_ENABLE -const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { - { 0, C8_8, C7_8, C6_8 }, - { 0, C9_8, C7_7, C6_7 }, - { 0, C9_7, C8_7, C6_6 }, - { 0, C9_6, C8_6, C7_6 }, - { 0, C9_5, C8_5, C7_5 }, - { 0, C9_4, C8_4, C7_4 }, - { 0, C9_3, C8_3, C7_3 }, - { 0, C9_2, C8_2, C7_2 }, - { 0, C9_1, C8_1, C7_1 }, - { 0, C2_9, C3_9, C4_9 }, - { 0, C1_9, C3_10, C4_10 }, - { 0, C1_10, C2_10, C4_11 }, - { 0, C1_11, C2_11, C3_11 }, - { 0, C1_13, C2_13, C3_13 }, - { 0, C1_14, C2_14, C3_14 }, - - { 0, C1_7, C2_7, C3_7 }, - { 0, C1_6, C2_6, C3_6 }, - { 0, C1_5, C2_5, C3_5 }, - { 0, C1_4, C2_4, C3_4 }, - { 0, C1_3, C2_3, C3_3 }, - { 0, C1_2, C2_2, C4_3 }, - { 0, C1_1, C3_2, C4_2 }, - { 0, C2_1, C3_1, C4_1 }, - { 0, C9_9, C8_9, C7_9 }, - { 0, C9_10, C8_10, C7_10 }, - { 0, C9_11, C8_11, C7_11 }, - { 0, C9_12, C8_12, C7_12 }, - { 0, C9_13, C8_13, C7_13 }, - { 0, C9_14, C8_14, C7_14 }, - { 0, C1_15, C2_15, C3_15 }, - - { 0, C1_8, C2_8, C3_8 }, - { 1, C9_6, C8_6, C7_6 }, - { 1, C9_5, C8_5, C7_5 }, - { 1, C9_4, C8_4, C7_4 }, - { 1, C9_3, C8_3, C7_3 }, - { 1, C9_2, C8_2, C7_2 }, - { 1, C9_1, C8_1, C7_1 }, - { 1, C2_9, C3_9, C4_9 }, - { 1, C1_9, C3_10, C4_10 }, - { 1, C1_10, C2_10, C4_11 }, - { 1, C1_11, C2_11, C3_11 }, - { 1, C1_12, C2_12, C3_12 }, - { 1, C1_13, C2_13, C3_13 }, - { 0, C1_16, C2_16, C3_16 }, - - { 1, C9_8, C7_7, C6_7 }, - { 1, C1_5, C2_5, C3_5 }, - { 1, C1_4, C2_4, C3_4 }, - { 1, C1_3, C2_3, C3_3 }, - { 1, C1_2, C2_2, C4_3 }, - { 1, C1_1, C3_2, C4_2 }, - { 1, C9_9, C8_9, C7_9 }, - { 1, C9_10, C8_10, C7_10 }, - { 1, C9_11, C8_11, C7_11 }, - { 1, C9_12, C8_12, C7_12 }, - { 1, C1_14, C2_14, C3_14 }, - { 1, C1_15, C2_15, C3_15 }, - { 1, C1_16, C2_16, C3_16 }, - { 0, C9_15, C8_15, C6_14 }, - - { 1, C8_8, C7_8, C6_8 }, - { 1, C1_8, C2_8, C3_8 }, - { 1, C1_7, C2_7, C3_7 }, - { 1, C2_1, C3_1, C4_1 }, - { 1, C9_14, C8_14, C7_14 }, - { 1, C9_15, C8_15, C6_14 }, - { 1, C9_16, C7_15, C6_15 }, - { 1, C8_16, C7_16, C6_16 }, - { 0, C8_16, C7_16, C6_16 }, - { 0, C9_16, C7_15, C6_15 } -}; - -led_config_t g_led_config = { - { - { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 }, - { 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29 }, - { 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, NO_LED, 42, 43 }, - { 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, NO_LED, 56, 57 }, - { 58, 59, 60, NO_LED, NO_LED, 61, NO_LED, NO_LED, 62, 63, 64, 65, NO_LED, 66, 67 } - }, { - { 0, 0 }, { 15, 0 }, { 30, 0 }, { 45, 0 }, { 60, 0 }, { 75, 0 }, { 90, 0 }, { 105, 0 }, { 120, 0 }, { 135, 0 }, { 150, 0 }, { 165, 0 }, { 180, 0 }, { 203, 0 }, { 224, 0 }, - { 4, 16 }, { 23, 16 }, { 38, 16 }, { 53, 16 }, { 68, 16 }, { 83, 16 }, { 98, 16 }, { 113, 16 }, { 128, 16 }, { 143, 16 }, { 158, 16 }, { 173, 16 }, { 188, 16 }, { 206, 16 }, { 224, 16 }, - { 6, 32 }, { 26, 32 }, { 41, 32 }, { 56, 32 }, { 71, 32 }, { 86, 32 }, { 101, 32 }, { 116, 32 }, { 131, 32 }, { 146, 32 }, { 161, 32 }, { 176, 32 }, { 201, 32 }, { 224, 32 }, - { 9, 48 }, { 34, 48 }, { 49, 48 }, { 64, 48 }, { 79, 48 }, { 94, 48 }, { 109, 48 }, { 124, 48 }, { 139, 48 }, { 154, 48 }, { 169, 48 }, { 189, 48 }, { 210, 48 }, { 224, 48 }, - { 2, 64 }, { 21, 64 }, { 39, 64 }, { 96, 64 }, { 150, 64 }, { 165, 64 }, { 180, 64 }, { 195, 64 }, { 210, 64 }, { 224, 64 } - }, { - 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, - 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, - 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, - 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, - 1, 1, 1, 4, 1, 1, 1, 1, 1, 1 - } -}; - -void suspend_power_down_kb(void) { - rgb_matrix_set_suspend_state(true); - suspend_power_down_user(); -} - -void suspend_wakeup_init_kb(void) { - rgb_matrix_set_suspend_state(false); - suspend_wakeup_init_user(); -} - -__attribute__ ((weak)) -void rgb_matrix_indicators_user(void) { - if (host_keyboard_led_state().caps_lock) { - rgb_matrix_set_color(30, 0xFF, 0xFF, 0xFF); - } -} -#endif diff --git a/keyboards/dztech/dz65rgb/dz65rgb.h b/keyboards/dztech/dz65rgb/dz65rgb.h index 371facc89e0d..734a1cff3f63 100644 --- a/keyboards/dztech/dz65rgb/dz65rgb.h +++ b/keyboards/dztech/dz65rgb/dz65rgb.h @@ -1,19 +1,28 @@ +/* Copyright 2021 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 +#ifdef KEYBOARD_dztech_dz65rgb_v1 + #include "v1.h" +#endif +#ifdef KEYBOARD_dztech_dz65rgb_v2 + #include "v2.h" +#endif +#ifdef KEYBOARD_dztech_dz65rgb_v3 + #include "v3.h" +#endif #include "quantum.h" - -#define XXX KC_NO - -#define LAYOUT_65_ansi( \ - K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, \ - K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, \ - K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, K2E, \ - K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, K3E, \ - K40, K41, K42, K45, K48, K49, K4A, K4B, K4D, K4E \ -) { \ - { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E }, \ - { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \ - { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, XXX, K2D, K2E }, \ - { K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, XXX, K3D, K3E }, \ - { K40, K41, K42, XXX, XXX, K45, XXX, XXX, K48, K49, K4A, K4B, XXX, K4D, K4E } \ -} diff --git a/keyboards/dztech/dz65rgb/readme.md b/keyboards/dztech/dz65rgb/readme.md index 8d7b95b3d600..e4d7a7a35db6 100644 --- a/keyboards/dztech/dz65rgb/readme.md +++ b/keyboards/dztech/dz65rgb/readme.md @@ -3,17 +3,25 @@ A customizable 65% RGB keyboard. * Keyboard Maintainer: [moyi4681](https://github.com/moyi4681) -* Hardware Supported: DZ65RGB V1 and V2 +* Hardware Supported: DZ65RGB V1,V2 and V3 * Hardware Availability: [KBDfans](https://kbdfans.com/) -There are two versions of the DZ65RGB. Please use the appropriate firmware for your board. +There are three versions of the DZ65RGB. Please use the appropriate firmware for your board. * V1: STM32F303 (Arm), takes .bin files -* V2: ATmega32U4 (AVR), takes .hex files +* V2: ATmega32U4 (AVR), takes .hex files, is31fl3731 rgbmatrix driver +* V3: ATmega32U4 (AVR), takes .bin files, is31fl3741 rgbmatrix driver + +## Bootloader mode + +To put in bootloader mode, hold the `Esc` key while plugging in the USB cable. or use reset key behind the pcb. + +## Making firmware Make example for this keyboard (after setting up your build environment): make dztech/dz65rgb/v1:default # Arm (STM32F303) make dztech/dz65rgb/v2:default # AVR (ATmega32U4) + make dztech/dz65rgb/v3:default # AVR (ATmega32U4) 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/dztech/dz65rgb/v1/config.h b/keyboards/dztech/dz65rgb/v1/config.h index cd474771602f..adfa934b04af 100644 --- a/keyboards/dztech/dz65rgb/v1/config.h +++ b/keyboards/dztech/dz65rgb/v1/config.h @@ -1,3 +1,18 @@ +/* Copyright 2019 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 /* USB Device descriptor parameter */ diff --git a/keyboards/dztech/dz65rgb/v1/readme.md b/keyboards/dztech/dz65rgb/v1/readme.md new file mode 100644 index 000000000000..ac433e5b8dc0 --- /dev/null +++ b/keyboards/dztech/dz65rgb/v1/readme.md @@ -0,0 +1,16 @@ +# DZ65RGB V1 + +A customizable 65% RGB keyboard. + +* Keyboard Maintainer: [moyi4681](https://github.com/moyi4681) +* Hardware Supported: DZ65RGB V1 +* Hardware Availability: [KBDfans](https://kbdfans.com/) + +## Making firmware + +Make example for this keyboard (after setting up your build environment): + + make dztech/dz65rgb/v1: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). + diff --git a/keyboards/dztech/dz65rgb/v1/v1.c b/keyboards/dztech/dz65rgb/v1/v1.c new file mode 100644 index 000000000000..8a3f0e27bf70 --- /dev/null +++ b/keyboards/dztech/dz65rgb/v1/v1.c @@ -0,0 +1,123 @@ +/* Copyright 2019 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 "v1.h" + +#ifdef RGB_MATRIX_ENABLE +const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { + { 0, C8_8, C7_8, C6_8 }, + { 0, C9_8, C7_7, C6_7 }, + { 0, C9_7, C8_7, C6_6 }, + { 0, C9_6, C8_6, C7_6 }, + { 0, C9_5, C8_5, C7_5 }, + { 0, C9_4, C8_4, C7_4 }, + { 0, C9_3, C8_3, C7_3 }, + { 0, C9_2, C8_2, C7_2 }, + { 0, C9_1, C8_1, C7_1 }, + { 0, C2_9, C3_9, C4_9 }, + { 0, C1_9, C3_10, C4_10 }, + { 0, C1_10, C2_10, C4_11 }, + { 0, C1_11, C2_11, C3_11 }, + { 0, C1_13, C2_13, C3_13 }, + { 0, C1_14, C2_14, C3_14 }, + + { 0, C1_7, C2_7, C3_7 }, + { 0, C1_6, C2_6, C3_6 }, + { 0, C1_5, C2_5, C3_5 }, + { 0, C1_4, C2_4, C3_4 }, + { 0, C1_3, C2_3, C3_3 }, + { 0, C1_2, C2_2, C4_3 }, + { 0, C1_1, C3_2, C4_2 }, + { 0, C2_1, C3_1, C4_1 }, + { 0, C9_9, C8_9, C7_9 }, + { 0, C9_10, C8_10, C7_10 }, + { 0, C9_11, C8_11, C7_11 }, + { 0, C9_12, C8_12, C7_12 }, + { 0, C9_13, C8_13, C7_13 }, + { 0, C9_14, C8_14, C7_14 }, + { 0, C1_15, C2_15, C3_15 }, + + { 0, C1_8, C2_8, C3_8 }, + { 1, C9_6, C8_6, C7_6 }, + { 1, C9_5, C8_5, C7_5 }, + { 1, C9_4, C8_4, C7_4 }, + { 1, C9_3, C8_3, C7_3 }, + { 1, C9_2, C8_2, C7_2 }, + { 1, C9_1, C8_1, C7_1 }, + { 1, C2_9, C3_9, C4_9 }, + { 1, C1_9, C3_10, C4_10 }, + { 1, C1_10, C2_10, C4_11 }, + { 1, C1_11, C2_11, C3_11 }, + { 1, C1_12, C2_12, C3_12 }, + { 1, C1_13, C2_13, C3_13 }, + { 0, C1_16, C2_16, C3_16 }, + + { 1, C9_8, C7_7, C6_7 }, + { 1, C1_5, C2_5, C3_5 }, + { 1, C1_4, C2_4, C3_4 }, + { 1, C1_3, C2_3, C3_3 }, + { 1, C1_2, C2_2, C4_3 }, + { 1, C1_1, C3_2, C4_2 }, + { 1, C9_9, C8_9, C7_9 }, + { 1, C9_10, C8_10, C7_10 }, + { 1, C9_11, C8_11, C7_11 }, + { 1, C9_12, C8_12, C7_12 }, + { 1, C1_14, C2_14, C3_14 }, + { 1, C1_15, C2_15, C3_15 }, + { 1, C1_16, C2_16, C3_16 }, + { 0, C9_15, C8_15, C6_14 }, + + { 1, C8_8, C7_8, C6_8 }, + { 1, C1_8, C2_8, C3_8 }, + { 1, C1_7, C2_7, C3_7 }, + { 1, C2_1, C3_1, C4_1 }, + { 1, C9_14, C8_14, C7_14 }, + { 1, C9_15, C8_15, C6_14 }, + { 1, C9_16, C7_15, C6_15 }, + { 1, C8_16, C7_16, C6_16 }, + { 0, C8_16, C7_16, C6_16 }, + { 0, C9_16, C7_15, C6_15 } +}; + +led_config_t g_led_config = { + { + { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 }, + { 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29 }, + { 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, NO_LED, 42, 43 }, + { 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, NO_LED, 56, 57 }, + { 58, 59, 60, NO_LED, NO_LED, 61, NO_LED, NO_LED, 62, 63, 64, 65, NO_LED, 66, 67 } + }, { + { 0, 0 }, { 15, 0 }, { 30, 0 }, { 45, 0 }, { 60, 0 }, { 75, 0 }, { 90, 0 }, { 105, 0 }, { 120, 0 }, { 135, 0 }, { 150, 0 }, { 165, 0 }, { 180, 0 }, { 203, 0 }, { 224, 0 }, + { 4, 16 }, { 23, 16 }, { 38, 16 }, { 53, 16 }, { 68, 16 }, { 83, 16 }, { 98, 16 }, { 113, 16 }, { 128, 16 }, { 143, 16 }, { 158, 16 }, { 173, 16 }, { 188, 16 }, { 206, 16 }, { 224, 16 }, + { 6, 32 }, { 26, 32 }, { 41, 32 }, { 56, 32 }, { 71, 32 }, { 86, 32 }, { 101, 32 }, { 116, 32 }, { 131, 32 }, { 146, 32 }, { 161, 32 }, { 176, 32 }, { 201, 32 }, { 224, 32 }, + { 9, 48 }, { 34, 48 }, { 49, 48 }, { 64, 48 }, { 79, 48 }, { 94, 48 }, { 109, 48 }, { 124, 48 }, { 139, 48 }, { 154, 48 }, { 169, 48 }, { 189, 48 }, { 210, 48 }, { 224, 48 }, + { 2, 64 }, { 21, 64 }, { 39, 64 }, { 96, 64 }, { 150, 64 }, { 165, 64 }, { 180, 64 }, { 195, 64 }, { 210, 64 }, { 224, 64 } + }, { + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 1, 1, 4, 1, 1, 1, 1, 1, 1 + } +}; + + +__attribute__ ((weak)) +void rgb_matrix_indicators_user(void) { + if (host_keyboard_led_state().caps_lock) { + rgb_matrix_set_color(30, 0xFF, 0xFF, 0xFF); + } +} +#endif diff --git a/keyboards/dztech/dz65rgb/v1/v1.h b/keyboards/dztech/dz65rgb/v1/v1.h new file mode 100644 index 000000000000..1811cefae6af --- /dev/null +++ b/keyboards/dztech/dz65rgb/v1/v1.h @@ -0,0 +1,34 @@ +/* Copyright 2019 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 XXX KC_NO + +#define LAYOUT_65_ansi( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, \ + K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, \ + K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, K2E, \ + K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, K3E, \ + K40, K41, K42, K45, K48, K49, K4A, K4B, K4D, K4E \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, XXX, K2D, K2E }, \ + { K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, XXX, K3D, K3E }, \ + { K40, K41, K42, XXX, XXX, K45, XXX, XXX, K48, K49, K4A, K4B, XXX, K4D, K4E } \ +} diff --git a/keyboards/dztech/dz65rgb/v2/config.h b/keyboards/dztech/dz65rgb/v2/config.h index ccd74275ae88..f86d65cd0685 100644 --- a/keyboards/dztech/dz65rgb/v2/config.h +++ b/keyboards/dztech/dz65rgb/v2/config.h @@ -1,3 +1,18 @@ +/* Copyright 2020 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 /* USB Device descriptor parameter */ diff --git a/keyboards/dztech/dz65rgb/v2/readme.md b/keyboards/dztech/dz65rgb/v2/readme.md new file mode 100644 index 000000000000..7bf376640384 --- /dev/null +++ b/keyboards/dztech/dz65rgb/v2/readme.md @@ -0,0 +1,16 @@ +# DZ65RGB V2 + +A customizable 65% RGB keyboard. + +* Keyboard Maintainer: [moyi4681](https://github.com/moyi4681) +* Hardware Supported: DZ65RGB V2 +* Hardware Availability: [KBDfans](https://kbdfans.com/) + +## Making firmware + +Make example for this keyboard (after setting up your build environment): + + make dztech/dz65rgb/v2: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). + diff --git a/keyboards/dztech/dz65rgb/v2/v2.c b/keyboards/dztech/dz65rgb/v2/v2.c new file mode 100644 index 000000000000..788709d98961 --- /dev/null +++ b/keyboards/dztech/dz65rgb/v2/v2.c @@ -0,0 +1,123 @@ +/* Copyright 2020 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 "v2.h" + +#ifdef RGB_MATRIX_ENABLE +const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { + { 0, C8_8, C7_8, C6_8 }, + { 0, C9_8, C7_7, C6_7 }, + { 0, C9_7, C8_7, C6_6 }, + { 0, C9_6, C8_6, C7_6 }, + { 0, C9_5, C8_5, C7_5 }, + { 0, C9_4, C8_4, C7_4 }, + { 0, C9_3, C8_3, C7_3 }, + { 0, C9_2, C8_2, C7_2 }, + { 0, C9_1, C8_1, C7_1 }, + { 0, C2_9, C3_9, C4_9 }, + { 0, C1_9, C3_10, C4_10 }, + { 0, C1_10, C2_10, C4_11 }, + { 0, C1_11, C2_11, C3_11 }, + { 0, C1_13, C2_13, C3_13 }, + { 0, C1_14, C2_14, C3_14 }, + + { 0, C1_7, C2_7, C3_7 }, + { 0, C1_6, C2_6, C3_6 }, + { 0, C1_5, C2_5, C3_5 }, + { 0, C1_4, C2_4, C3_4 }, + { 0, C1_3, C2_3, C3_3 }, + { 0, C1_2, C2_2, C4_3 }, + { 0, C1_1, C3_2, C4_2 }, + { 0, C2_1, C3_1, C4_1 }, + { 0, C9_9, C8_9, C7_9 }, + { 0, C9_10, C8_10, C7_10 }, + { 0, C9_11, C8_11, C7_11 }, + { 0, C9_12, C8_12, C7_12 }, + { 0, C9_13, C8_13, C7_13 }, + { 0, C9_14, C8_14, C7_14 }, + { 0, C1_15, C2_15, C3_15 }, + + { 0, C1_8, C2_8, C3_8 }, + { 1, C9_6, C8_6, C7_6 }, + { 1, C9_5, C8_5, C7_5 }, + { 1, C9_4, C8_4, C7_4 }, + { 1, C9_3, C8_3, C7_3 }, + { 1, C9_2, C8_2, C7_2 }, + { 1, C9_1, C8_1, C7_1 }, + { 1, C2_9, C3_9, C4_9 }, + { 1, C1_9, C3_10, C4_10 }, + { 1, C1_10, C2_10, C4_11 }, + { 1, C1_11, C2_11, C3_11 }, + { 1, C1_12, C2_12, C3_12 }, + { 1, C1_13, C2_13, C3_13 }, + { 0, C1_16, C2_16, C3_16 }, + + { 1, C9_8, C7_7, C6_7 }, + { 1, C1_5, C2_5, C3_5 }, + { 1, C1_4, C2_4, C3_4 }, + { 1, C1_3, C2_3, C3_3 }, + { 1, C1_2, C2_2, C4_3 }, + { 1, C1_1, C3_2, C4_2 }, + { 1, C9_9, C8_9, C7_9 }, + { 1, C9_10, C8_10, C7_10 }, + { 1, C9_11, C8_11, C7_11 }, + { 1, C9_12, C8_12, C7_12 }, + { 1, C1_14, C2_14, C3_14 }, + { 1, C1_15, C2_15, C3_15 }, + { 1, C1_16, C2_16, C3_16 }, + { 0, C9_15, C8_15, C6_14 }, + + { 1, C8_8, C7_8, C6_8 }, + { 1, C1_8, C2_8, C3_8 }, + { 1, C1_7, C2_7, C3_7 }, + { 1, C2_1, C3_1, C4_1 }, + { 1, C9_14, C8_14, C7_14 }, + { 1, C9_15, C8_15, C6_14 }, + { 1, C9_16, C7_15, C6_15 }, + { 1, C8_16, C7_16, C6_16 }, + { 0, C8_16, C7_16, C6_16 }, + { 0, C9_16, C7_15, C6_15 } +}; + +led_config_t g_led_config = { + { + { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 }, + { 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29 }, + { 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, NO_LED, 42, 43 }, + { 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, NO_LED, 56, 57 }, + { 58, 59, 60, NO_LED, NO_LED, 61, NO_LED, NO_LED, 62, 63, 64, 65, NO_LED, 66, 67 } + }, { + { 0, 0 }, { 15, 0 }, { 30, 0 }, { 45, 0 }, { 60, 0 }, { 75, 0 }, { 90, 0 }, { 105, 0 }, { 120, 0 }, { 135, 0 }, { 150, 0 }, { 165, 0 }, { 180, 0 }, { 203, 0 }, { 224, 0 }, + { 4, 16 }, { 23, 16 }, { 38, 16 }, { 53, 16 }, { 68, 16 }, { 83, 16 }, { 98, 16 }, { 113, 16 }, { 128, 16 }, { 143, 16 }, { 158, 16 }, { 173, 16 }, { 188, 16 }, { 206, 16 }, { 224, 16 }, + { 6, 32 }, { 26, 32 }, { 41, 32 }, { 56, 32 }, { 71, 32 }, { 86, 32 }, { 101, 32 }, { 116, 32 }, { 131, 32 }, { 146, 32 }, { 161, 32 }, { 176, 32 }, { 201, 32 }, { 224, 32 }, + { 9, 48 }, { 34, 48 }, { 49, 48 }, { 64, 48 }, { 79, 48 }, { 94, 48 }, { 109, 48 }, { 124, 48 }, { 139, 48 }, { 154, 48 }, { 169, 48 }, { 189, 48 }, { 210, 48 }, { 224, 48 }, + { 2, 64 }, { 21, 64 }, { 39, 64 }, { 96, 64 }, { 150, 64 }, { 165, 64 }, { 180, 64 }, { 195, 64 }, { 210, 64 }, { 224, 64 } + }, { + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 1, 1, 4, 1, 1, 1, 1, 1, 1 + } +}; + + +__attribute__ ((weak)) +void rgb_matrix_indicators_user(void) { + if (host_keyboard_led_state().caps_lock) { + rgb_matrix_set_color(30, 0xFF, 0xFF, 0xFF); + } +} +#endif diff --git a/keyboards/dztech/dz65rgb/v2/v2.h b/keyboards/dztech/dz65rgb/v2/v2.h new file mode 100644 index 000000000000..ead68e8760dd --- /dev/null +++ b/keyboards/dztech/dz65rgb/v2/v2.h @@ -0,0 +1,34 @@ +/* Copyright 2020 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 XXX KC_NO + +#define LAYOUT_65_ansi( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, \ + K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, \ + K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, K2E, \ + K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, K3E, \ + K40, K41, K42, K45, K48, K49, K4A, K4B, K4D, K4E \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, XXX, K2D, K2E }, \ + { K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, XXX, K3D, K3E }, \ + { K40, K41, K42, XXX, XXX, K45, XXX, XXX, K48, K49, K4A, K4B, XXX, K4D, K4E } \ +} diff --git a/keyboards/dztech/dz65rgb/v3/config.h b/keyboards/dztech/dz65rgb/v3/config.h new file mode 100755 index 000000000000..c348e323d475 --- /dev/null +++ b/keyboards/dztech/dz65rgb/v3/config.h @@ -0,0 +1,57 @@ +/* Copyright 2021 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 "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x445A +#define PRODUCT_ID 0x1424 +#define DEVICE_VER 0x0003 +#define MANUFACTURER DZTECH +#define PRODUCT DZ65RGBV3 + +/* key matrix size */ +#define MATRIX_ROWS 5 +#define MATRIX_COLS 15 +#define MATRIX_ROW_PINS { F0, F1, F4, E6, C6 } +#define MATRIX_COL_PINS { F7, F6, F5, C7, B0, B1, B2, B3, B4, D7, D6, D4, D5, D3, D2} +#define UNUSED_PINS + +/* COL2ROW, ROW2COL*/ +#define DIODE_DIRECTION COL2ROW + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 +/* disable these deprecated features by default */ +#define NO_ACTION_MACRO +#define NO_ACTION_FUNCTION +#ifdef RGB_MATRIX_ENABLE +#define RGB_DISABLE_AFTER_TIMEOUT 0 // number of ticks to wait until disabling effects +#define RGB_DISABLE_WHEN_USB_SUSPENDED true // 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 +#define RGB_MATRIX_STARTUP_MODE RGB_MATRIX_CYCLE_ALL +#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_2 0b0110000 // this is here for compliancy reasons. +#define DRIVER_COUNT 1 +#define DRIVER_1_LED_TOTAL 68 +#define DRIVER_LED_TOTAL DRIVER_1_LED_TOTAL +#define DRIVER_INDICATOR_LED_TOTAL 0 +#endif diff --git a/keyboards/dztech/dz65rgb/v3/readme.md b/keyboards/dztech/dz65rgb/v3/readme.md new file mode 100644 index 000000000000..e5ae7eec7cea --- /dev/null +++ b/keyboards/dztech/dz65rgb/v3/readme.md @@ -0,0 +1,19 @@ +# DZ65RGB V3 + +A customizable 65% RGB keyboard. + +* Keyboard Maintainer: [moyi4681](https://github.com/moyi4681) +* Hardware Supported: DZ65RGB V3 +* Hardware Availability: [KBDfans](https://kbdfans.com/) + +## Bootloader mode + +To put in bootloader mode, hold the `Esc` key while plugging in the USB cable. or use reset key behind the pcb. + +## Making firmware + +Make example for this keyboard (after setting up your build environment): + + make dztech/dz65rgb/v3: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). diff --git a/keyboards/dztech/dz65rgb/v3/rules.mk b/keyboards/dztech/dz65rgb/v3/rules.mk new file mode 100755 index 000000000000..36358fe4d921 --- /dev/null +++ b/keyboards/dztech/dz65rgb/v3/rules.mk @@ -0,0 +1,24 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = lufa-ms + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output +RGB_MATRIX_ENABLE = yes # Use RGB matrix +RGB_MATRIX_DRIVER = IS31FL3741 diff --git a/keyboards/dztech/dz65rgb/v3/v3.c b/keyboards/dztech/dz65rgb/v3/v3.c new file mode 100755 index 000000000000..dec75814ca0c --- /dev/null +++ b/keyboards/dztech/dz65rgb/v3/v3.c @@ -0,0 +1,125 @@ +/* Copyright 2021 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 "v3.h" + +#ifdef RGB_MATRIX_ENABLE + +const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { + {0, CS21_SW1, CS20_SW1, CS19_SW1}, + {0, CS21_SW2, CS20_SW2, CS19_SW2}, + {0, CS21_SW3, CS20_SW3, CS19_SW3}, + {0, CS21_SW4, CS20_SW4, CS19_SW4}, + {0, CS21_SW5, CS20_SW5, CS19_SW5}, + {0, CS21_SW6, CS20_SW6, CS19_SW6}, + {0, CS21_SW7, CS20_SW7, CS19_SW7}, + {0, CS21_SW8, CS20_SW8, CS19_SW8}, + {0, CS24_SW1, CS23_SW1, CS22_SW1}, + {0, CS24_SW2, CS23_SW2, CS22_SW2}, + {0, CS24_SW3, CS23_SW3, CS22_SW3}, + {0, CS24_SW4, CS23_SW4, CS22_SW4}, + {0, CS24_SW5, CS23_SW5, CS22_SW5}, + {0, CS24_SW6, CS23_SW6, CS22_SW6}, + {0, CS24_SW7, CS23_SW7, CS22_SW7}, + + {0, CS15_SW1, CS14_SW1, CS13_SW1}, + {0, CS15_SW2, CS14_SW2, CS13_SW2}, + {0, CS15_SW3, CS14_SW3, CS13_SW3}, + {0, CS15_SW4, CS14_SW4, CS13_SW4}, + {0, CS15_SW5, CS14_SW5, CS13_SW5}, + {0, CS15_SW6, CS14_SW6, CS13_SW6}, + {0, CS15_SW7, CS14_SW7, CS13_SW7}, + {0, CS15_SW8, CS14_SW8, CS13_SW8}, + {0, CS30_SW1, CS29_SW1, CS28_SW1}, + {0, CS30_SW2, CS29_SW2, CS28_SW2}, + {0, CS30_SW3, CS29_SW3, CS28_SW3}, + {0, CS30_SW4, CS29_SW4, CS28_SW4}, + {0, CS30_SW5, CS29_SW5, CS28_SW5}, + {0, CS30_SW6, CS29_SW6, CS28_SW6}, + {0, CS30_SW7, CS29_SW7, CS28_SW7}, + + {0, CS12_SW1, CS11_SW1, CS10_SW1}, + {0, CS12_SW2, CS11_SW2, CS10_SW2}, + {0, CS12_SW3, CS11_SW3, CS10_SW3}, + {0, CS12_SW4, CS11_SW4, CS10_SW4}, + {0, CS12_SW5, CS11_SW5, CS10_SW5}, + {0, CS12_SW6, CS11_SW6, CS10_SW6}, + {0, CS12_SW7, CS11_SW7, CS10_SW7}, + {0, CS12_SW8, CS11_SW8, CS10_SW8}, + {0, CS33_SW1, CS32_SW1, CS31_SW1}, + {0, CS33_SW2, CS32_SW2, CS31_SW2}, + {0, CS33_SW3, CS32_SW3, CS31_SW3}, + {0, CS33_SW4, CS32_SW4, CS31_SW4}, + {0, CS33_SW5, CS32_SW5, CS31_SW5}, + {0, CS33_SW7, CS32_SW7, CS31_SW7}, + + {0, CS9_SW1, CS8_SW1, CS7_SW1}, + {0, CS9_SW2, CS8_SW2, CS7_SW2}, + {0, CS9_SW3, CS8_SW3, CS7_SW3}, + {0, CS9_SW4, CS8_SW4, CS7_SW4}, + {0, CS9_SW5, CS8_SW5, CS7_SW5}, + {0, CS9_SW6, CS8_SW6, CS7_SW6}, + {0, CS9_SW7, CS8_SW7, CS7_SW7}, + {0, CS9_SW8, CS8_SW8, CS7_SW8}, + {0, CS36_SW1, CS35_SW1, CS34_SW1}, + {0, CS36_SW2, CS35_SW2, CS34_SW2}, + {0, CS36_SW3, CS35_SW3, CS34_SW3}, + {0, CS36_SW4, CS35_SW4, CS34_SW4}, + {0, CS36_SW5, CS35_SW5, CS34_SW5}, + {0, CS36_SW7, CS35_SW7, CS34_SW7}, + + {0, CS3_SW1, CS2_SW1, CS1_SW1}, + {0, CS3_SW2, CS2_SW2, CS1_SW2}, + {0, CS3_SW3, CS2_SW3, CS1_SW3}, + {0, CS3_SW6, CS2_SW6, CS1_SW6}, + {0, CS39_SW1, CS38_SW1, CS37_SW1}, + {0, CS39_SW2, CS38_SW2, CS37_SW2}, + {0, CS39_SW3, CS38_SW3, CS37_SW3}, + {0, CS39_SW4, CS38_SW4, CS37_SW4}, + {0, CS39_SW5, CS38_SW5, CS37_SW5}, + {0, CS39_SW7, CS38_SW7, CS37_SW7} + +}; +led_config_t g_led_config = { { + { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 }, + { 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29 }, + { 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, NO_LED,42, 43 }, + { 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, NO_LED,55, 56, 57 }, + { 58, 59, 60, NO_LED, NO_LED, 61, NO_LED, NO_LED, NO_LED, 62, 63, 64, 65, 66, 67 } +}, { + {0,0},{15,0},{30,0},{45,0},{60,0},{75,0},{90,0},{105,0},{120,0},{135,0},{150,0},{165,0},{180,0},{203,0},{224,0}, + {4,16},{23,16},{38,16},{53,16},{68,16},{83,16},{98,16},{113,16},{128,16},{143,16},{158,16},{173,16},{188,16},{206,16},{224,16}, + {6,32},{26,32},{41,32},{56,32},{71,32},{86,32},{101,32},{116,32},{131,32},{146,32},{161,32},{176,32},{201,32},{224,32}, + {9,48},{34,48},{49,48},{64,48},{79,48},{94,48},{109,48},{124,48},{139,48},{154,48},{169,48},{189,48},{210,48},{224,48}, + { 2, 64 }, { 21, 64 }, { 39, 64 }, { 96, 64 }, { 150, 64 }, { 165, 64 }, { 180, 64 }, { 195, 64 }, { 210, 64 }, { 224, 64 } +}, { + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + 1, 1, 1, 4, 1, 1, 1, 1, 1, 1 +} }; + + +__attribute__ ((weak)) +void rgb_matrix_indicators_user(void) +{ + if (host_keyboard_led_state().caps_lock) + { + rgb_matrix_set_color(30, 0xFF, 0xFF, 0xFF); + } +} +#endif diff --git a/keyboards/dztech/dz65rgb/v3/v3.h b/keyboards/dztech/dz65rgb/v3/v3.h new file mode 100755 index 000000000000..a36069d79550 --- /dev/null +++ b/keyboards/dztech/dz65rgb/v3/v3.h @@ -0,0 +1,35 @@ +/* Copyright 2021 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 XXX KC_NO + +#define LAYOUT_65_ansi( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, \ + K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, \ + K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, K2E, \ + K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3C, K3D, K3E, \ + K40, K41, K42, K45, K49, K4A, K4B, K4C, K4D, K4E \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, XXX, K2D, K2E }, \ + { K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, XXX, K3C, K3D, K3E }, \ + { K40, K41, K42, XXX, XXX, K45, XXX, XXX, XXX, K49, K4A, K4B, K4C, K4D, K4E } \ +} diff --git a/keyboards/fc980c/config.h b/keyboards/fc980c/config.h index 8400d2cdabf2..b74ca64a5c3c 100644 --- a/keyboards/fc980c/config.h +++ b/keyboards/fc980c/config.h @@ -21,11 +21,14 @@ along with this program. If not, see . #include "config_common.h" /* USB Device descriptor parameter */ -#define VENDOR_ID 0xFEED +#define VENDOR_ID 0x4853 #define PRODUCT_ID 0x980C #define DEVICE_VER 0x0100 -#define MANUFACTURER QMK -#define PRODUCT Leopold FC980C with QMK +#define MANUFACTURER Hasu +#define PRODUCT FC980C + +/* Maximum dynamic keymap layers (constrained by EEPROM space) */ +#define DYNAMIC_KEYMAP_LAYER_COUNT 3 /* key matrix size */ #define MATRIX_ROWS 8 diff --git a/keyboards/fc980c/keymaps/via/keymap.c b/keyboards/fc980c/keymaps/via/keymap.c new file mode 100644 index 000000000000..f498cd43a017 --- /dev/null +++ b/keyboards/fc980c/keymaps/via/keymap.c @@ -0,0 +1,41 @@ +/* +Copyright 2017 Balz Guenat + +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_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_PGUP, KC_PGDN, + 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_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_P7, KC_P8, KC_P9, KC_PPLS, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_P4, KC_P5, KC_P6, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RCTL, MO(1), KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT), + [1] = LAYOUT( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_HOME, KC_END, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_SLCK, KC_PAUS, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_PGUP, _______, _______, _______, _______, + _______, _______, _______, _______, _______, KC_APP, _______, KC_HOME, KC_PGDN, KC_END, _______, _______), + [2] = LAYOUT( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), +}; diff --git a/keyboards/fc980c/keymaps/via/rules.mk b/keyboards/fc980c/keymaps/via/rules.mk new file mode 100644 index 000000000000..36b7ba9cbc98 --- /dev/null +++ b/keyboards/fc980c/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +VIA_ENABLE = yes +LTO_ENABLE = yes diff --git a/keyboards/gray_studio/cod67/rules.mk b/keyboards/gray_studio/cod67/rules.mk index 129bd624cce0..2e066d99150e 100644 --- a/keyboards/gray_studio/cod67/rules.mk +++ b/keyboards/gray_studio/cod67/rules.mk @@ -11,6 +11,9 @@ MCU = atmega32u4 # ATmega328P USBasp BOOTLOADER = lufa-ms +# This board uses the older unsafe 6k version of lufa-ms +BOOTLOADER_SIZE = 6144 + # Build Options # change yes to no to disable # diff --git a/keyboards/handwired/pteron/keymaps/alzafacon/config.h b/keyboards/handwired/pteron/keymaps/alzafacon/config.h new file mode 100644 index 000000000000..3bc36a62ae50 --- /dev/null +++ b/keyboards/handwired/pteron/keymaps/alzafacon/config.h @@ -0,0 +1,22 @@ + /* Copyright 2021 Fidel Coria + * + * 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 + +/* override diode direction from keyboard config */ +/* COL2ROW or ROW2COL */ +#undef DIODE_DIRECTION +#define DIODE_DIRECTION COL2ROW diff --git a/keyboards/handwired/pteron/keymaps/alzafacon/keymap.c b/keyboards/handwired/pteron/keymaps/alzafacon/keymap.c new file mode 100644 index 000000000000..bbb77fa87c64 --- /dev/null +++ b/keyboards/handwired/pteron/keymaps/alzafacon/keymap.c @@ -0,0 +1,120 @@ + /* Copyright 2021 Fidel Coria + * + * 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 pteron_layers { + _QWERTY, + _LOWER, + _RAISE, + _ADJUST +}; + + +#define LOWER MO(_LOWER) +#define RAISE MO(_RAISE) + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + +/* Qwerty + * +-----------------------------------------+ +-----------------------------------------+ + * | ` | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | Bksp | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | Tab | Q | W | E | R | T | | Y | U | I | O | P | Del | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | Esc | A | S | D | F | G | | H | J | K | L | ; | " | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | Shift| Z | X | C | V | B | | N | M | , | . | / |Enter | + * +-------------+------+------+------+------| |------+------+------+------+-------------+ + * |Lower | SPC | Alt | GUI | | Alt | GUI | SPC |Raise | + * +---------------------------+ +---------------------------+ + */ +[_QWERTY] = LAYOUT( + KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, 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_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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT, + LOWER, KC_SPC, KC_LALT, KC_LGUI, KC_RALT, KC_RGUI, KC_SPC, RAISE +), + +/* Lower + * +-----------------------------------------+ +-----------------------------------------+ + * | ~ | ! | @ | # | $ | % | | ^ | & | * | ( | ) | Bksp | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | ~ | ! | @ | # | $ | % | | ^ | & | * | ( | ) | Del | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | Del | F1 | F2 | F3 | F4 | F5 | | F6 | _ | + | { | } | | | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | | F7 | F8 | F9 | F10 | F11 | | F12 |ISO ~ |ISO | | | | | + * +-------------+------+------+------+------| |------+------+------+------+-------------+ + * | | | | | | Next | Vol- | Vol+ | Play | + * +---------------------------+ +---------------------------+ + */ +[_LOWER] = LAYOUT( + 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_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_DEL, + 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 +), + +/* Raise + * +-----------------------------------------+ +-----------------------------------------+ + * | ` | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | Bksp | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | ` | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | Del | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | Del | F1 | F2 | F3 | F4 | F5 | | F6 | - | = | [ | ] | \ | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | | F7 | F8 | F9 | F10 | F11 | | F12 |ISO # |ISO / | | | | + * +-------------+------+------+------+------| |------+------+------+------+-------------+ + * | | | | | | Next | Vol- | Vol+ | Play | + * +---------------------------+ +---------------------------+ + */ +[_RAISE] = LAYOUT( + 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_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_DEL, + 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 +), + +/* Adjust (Lower + Raise) + * +-----------------------------------------+ +-----------------------------------------+ + * | F1 | F2 | F3 | F4 | F5 | F6 | | F7 | F8 | F9 | F10 | F11 | F12 | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | | Reset| | | | | | | | | | | Del | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | | | |Aud on|AudOff|AGnorm| |AGswap|Qwerty|Colemk|Dvorak| | | + * |------+------+------+------+------+------| |------+------+------+------+------+------| + * | |Voice-|Voice+|Mus on|MusOff|MidiOn| |MidOff| | | | | | + * +-------------+------+------+------+------| |------+------+------+------+-------------+ + * | | | | | | | | | | + * +---------------------------+ +---------------------------+ + */ +[_ADJUST] = LAYOUT( + KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, + _______, RESET, DEBUG, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______ +) + +}; + +layer_state_t layer_state_set_user(layer_state_t state) { + return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST); +} diff --git a/keyboards/handwired/pteron/keymaps/alzafacon/readme.md b/keyboards/handwired/pteron/keymaps/alzafacon/readme.md new file mode 100644 index 000000000000..0bc5f2704fde --- /dev/null +++ b/keyboards/handwired/pteron/keymaps/alzafacon/readme.md @@ -0,0 +1,4 @@ +# alzafacon pteron layout + +This keymap is for builds with elite-c controllers. +Also notice `DIODE_DIRECTION COL2ROW`. I prefer to hand-wire this way. diff --git a/keyboards/handwired/pteron/keymaps/alzafacon/rules.mk b/keyboards/handwired/pteron/keymaps/alzafacon/rules.mk new file mode 100644 index 000000000000..03323308e775 --- /dev/null +++ b/keyboards/handwired/pteron/keymaps/alzafacon/rules.mk @@ -0,0 +1,2 @@ +# for elite-c +BOOTLOADER = atmel-dfu diff --git a/keyboards/handwired/split89/config.h b/keyboards/handwired/split89/config.h new file mode 100644 index 000000000000..d78535a20107 --- /dev/null +++ b/keyboards/handwired/split89/config.h @@ -0,0 +1,163 @@ +/* Copyright 2021 jurassic73 + +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 "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0xFEED +#define PRODUCT_ID 0x0000 +#define DEVICE_VER 0x0001 +#define MANUFACTURER jurassic73 +#define PRODUCT split89 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ + +/* key matrix size +ROWS = total count of rows for both sides - this is broken out accordingly in split.h +COLS = number of cols per side which curently needs to be equal so there are blank columns for the left side in the split89.h file + */ +#define MATRIX_ROWS 12 +#define MATRIX_COLS 10 + +/* Left side matrix */ +#define MATRIX_ROW_PINS { F6, F7, B1, B3, B2, B6 } +#define MATRIX_COL_PINS { F5, F4, B5, B4, E6, D7, C6, D4, D2, D3 } +/* Right side matrix */ +#define MATRIX_ROW_PINS_RIGHT { F6, F7, B1, B3, B2, B6 } +#define MATRIX_COL_PINS_RIGHT { F5, F4, B5, B4, E6, D7, C6, D4, D2, D3 } + +/* this will be tied to high (VCC with a 2k to 10k resistor) on the left keyboard half and tied to low (GND using a wire jumper only) on the right keyboard half. This allows a user to plug in a USB cable to either side and function correctly with or without a TRS/TRRS cable with a single hex file. */ +#define SPLIT_HAND_PIN D1 + +/* COL2ROW, ROW2COL */ +#define DIODE_DIRECTION COL2ROW + +/* handedness */ +/* + * Split Keyboard specific options, make sure you have 'SPLIT_KEYBOARD = yes' in your rules.mk, and define SOFT_SERIAL_PIN. + */ +#define SOFT_SERIAL_PIN D0 // or D1, D2, D3, E6 +#define USE_SERIAL + +//#define LED_NUM_LOCK_PIN B0 +//#define LED_CAPS_LOCK_PIN B1 +//#define LED_SCROLL_LOCK_PIN B2 +//#define LED_COMPOSE_PIN B3 +//#define LED_KANA_PIN B4 + +//#define BACKLIGHT_PIN B7 +//#define BACKLIGHT_LEVELS 3 +//#define BACKLIGHT_BREATHING + +//#define RGB_DI_PIN E2 +//#ifdef RGB_DI_PIN +//# define RGBLED_NUM 16 +//# 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 */ +/*== all animations enable ==*/ +//# define RGBLIGHT_ANIMATIONS +/*== or choose animations ==*/ +//# 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 +/*== customize breathing effect ==*/ +/*==== (DEFAULT) use fixed table instead of exp() and sin() ====*/ +//# define RGBLIGHT_BREATHE_TABLE_SIZE 256 // 256(default) or 128 or 64 +/*==== use exp() and sin() ====*/ +//# define RGBLIGHT_EFFECT_BREATHE_CENTER 1.85 // 1 to 2.7 +//# define RGBLIGHT_EFFECT_BREATHE_MAX 255 // 0 to 255 +//#endif + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* define if matrix has ghost (lacks anti-ghosting diodes) */ +//#define MATRIX_HAS_GHOST + +/* 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 + +/* If defined, GRAVE_ESC will always act as ESC when CTRL is held. + * This is useful for the Windows task manager shortcut (ctrl+shift+esc). + */ +//#define GRAVE_ESC_CTRL_OVERRIDE + +/* + * Force NKRO + * + * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved + * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the + * makefile for this to work.) + * + * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N) + * until the next keyboard reset. + * + * NKRO may prevent your keystrokes from being detected in the BIOS, but it is + * fully operational during normal computer usage. + * + * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N) + * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by + * bootmagic, NKRO mode will always be enabled until it is toggled again during a + * power-up. + * + */ +//#define FORCE_NKRO + +/* + * Feature disable options + * These options are also useful to firmware size reduction. + */ + +/* disable debug print */ +//#define NO_DEBUG + +/* disable print */ +//#define NO_PRINT + +/* disable action features */ +//#define NO_ACTION_LAYER +//#define NO_ACTION_TAPPING +//#define NO_ACTION_ONESHOT + +/* disable these deprecated features by default */ +#define NO_ACTION_MACRO +#define NO_ACTION_FUNCTION + +/* Bootmagic Lite key configuration */ +//#define BOOTMAGIC_LITE_ROW 0 +//#define BOOTMAGIC_LITE_COLUMN 0 diff --git a/keyboards/handwired/split89/info.json b/keyboards/handwired/split89/info.json new file mode 100644 index 000000000000..bbdf48966ed2 --- /dev/null +++ b/keyboards/handwired/split89/info.json @@ -0,0 +1,12 @@ +{ + "keyboard_name": "split89", + "maintainer": "jurassic73", + "url": "https://github.com/jurassic73/split89", + "width": 21, + "height": 6.5, + "layouts": { + "LAYOUT": { + "layout": [{"label":"Esc", "x":0, "y":0}, {"label":"F1", "x":2, "y":0}, {"label":"F2", "x":3, "y":0}, {"label":"F3", "x":4, "y":0}, {"label":"F4", "x":5, "y":0}, {"label":"F5", "x":6, "y":0}, {"label":"F6", "x":10.25, "y":0}, {"label":"F7", "x":11.25, "y":0}, {"label":"F8", "x":12.25, "y":0}, {"label":"F9", "x":13.75, "y":0}, {"label":"F10", "x":14.75, "y":0}, {"label":"F11", "x":15.75, "y":0}, {"label":"F12", "x":16.75, "y":0}, {"label":"PrtSc", "x":18, "y":0}, {"label":"Scroll Lock", "x":19, "y":0}, {"label":"Pause", "x":20, "y":0}, {"label":"~", "x":0, "y":1.5}, {"label":"!", "x":1, "y":1.5}, {"label":"@", "x":2, "y":1.5}, {"label":"#", "x":3, "y":1.5}, {"label":"$", "x":4, "y":1.5}, {"label":"%", "x":5, "y":1.5}, {"label":"^", "x":6, "y":1.5}, {"label":"&", "x":9.75, "y":1.5}, {"label":"*", "x":10.75, "y":1.5}, {"label":"(", "x":11.75, "y":1.5}, {"label":")", "x":12.75, "y":1.5}, {"label":"_", "x":13.75, "y":1.5}, {"label":"+", "x":14.75, "y":1.5}, {"label":"Backspace", "x":15.75, "y":1.5, "w":2}, {"label":"Insert", "x":18, "y":1.5}, {"label":"Home", "x":19, "y":1.5}, {"label":"PgUp", "x":20, "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":9.25, "y":2.5}, {"label":"U", "x":10.25, "y":2.5}, {"label":"I", "x":11.25, "y":2.5}, {"label":"O", "x":12.25, "y":2.5}, {"label":"P", "x":13.25, "y":2.5}, {"label":"{", "x":14.25, "y":2.5}, {"label":"}", "x":15.25, "y":2.5}, {"label":"|", "x":16.25, "y":2.5, "w":1.5}, {"label":"Delete", "x":18, "y":2.5}, {"label":"End", "x":19, "y":2.5}, {"label":"PgDn", "x":20, "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":9.5, "y":3.5}, {"label":"J", "x":10.5, "y":3.5}, {"label":"K", "x":11.5, "y":3.5}, {"label":"L", "x":12.5, "y":3.5}, {"label":":", "x":13.5, "y":3.5}, {"label":"\"", "x":14.5, "y":3.5}, {"label":"Enter", "x":15.5, "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":10, "y":4.5}, {"label":"M", "x":11, "y":4.5}, {"label":"<", "x":12, "y":4.5}, {"label":">", "x":13, "y":4.5}, {"label":"?", "x":14, "y":4.5}, {"label":"Shift", "x":15, "y":4.5, "w":2.75}, {"label":"\u2191", "x":19, "y":4.5}, {"label":"Ctrl", "x":0, "y":5.5, "w":1.25}, {"label":"Fn", "x":1.25, "y":5.5, "w":1.25}, {"label":"Win", "x":2.5, "y":5.5, "w":1.25}, {"label":"Alt", "x":3.75, "y":5.5, "w":1.25}, {"x":5, "y":5.5, "w":2.25}, {"x":10, "y":5.5, "w":2.75}, {"label":"Alt", "x":12.75, "y":5.5, "w":1.25}, {"label":"Win", "x":14, "y":5.5, "w":1.25}, {"label":"Menu", "x":15.25, "y":5.5, "w":1.25}, {"label":"Ctrl", "x":16.5, "y":5.5, "w":1.25}, {"label":"\u2190", "x":18, "y":5.5}, {"label":"\u2193", "x":19, "y":5.5}, {"label":"\u2192", "x":20, "y":5.5}] + } + } +} \ No newline at end of file diff --git a/keyboards/handwired/split89/keymaps/default/keymap.c b/keyboards/handwired/split89/keymaps/default/keymap.c new file mode 100644 index 000000000000..3b60ef4f6867 --- /dev/null +++ b/keyboards/handwired/split89/keymaps/default/keymap.c @@ -0,0 +1,42 @@ +/* Copyright 2021 jurassic73 + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + BASE, + AUD, +}; +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [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_SLCK, KC_PAUS, + 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_GRV, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, + KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_Y, KC_J, KC_K, KC_L, KC_SCLN,KC_QUOT, KC_ENT, + KC_CAPS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_H, KC_M, KC_COMM,KC_DOT, KC_SLSH, KC_RSHIFT, KC_UP, + KC_LSFT, KC_LCTL,MO(1),KC_LGUI,KC_LALT,KC_SPACE, KC_N, KC_SPACE, KC_RALT,KC_RGUI, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + /* Volume */ + [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,KC_TRNS, KC_VOLU, + KC_TRNS,KC_TRNS,KC_TRNS, KC_TRNS,KC_TRNS,KC_MEDIA_PLAY_PAUSE, KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS, KC_MPRV, KC_VOLD, KC_MNXT + ), +}; diff --git a/keyboards/handwired/split89/keymaps/default/readme.md b/keyboards/handwired/split89/keymaps/default/readme.md new file mode 100644 index 000000000000..086d8977a09d --- /dev/null +++ b/keyboards/handwired/split89/keymaps/default/readme.md @@ -0,0 +1,6 @@ +# The default keymap for split89 + +A 2nd layer is configured and activated while holding down the Aud key. + +![image](https://i.imgur.com/h1C4d9t.png) + diff --git a/keyboards/handwired/split89/readme.md b/keyboards/handwired/split89/readme.md new file mode 100644 index 000000000000..c3caf6a7fd7b --- /dev/null +++ b/keyboards/handwired/split89/readme.md @@ -0,0 +1,18 @@ +# split89 + +![split89](https://i.imgur.com/OExxlQx.jpeg) + +An 89-key split TKL with 3d printed case and powered with Pro Micro controllers. + +* Full build documented here: [https://github.com/jurassic73/split89](https://github.com/jurassic73/split89) + +* Keyboard Maintainer: [jurassic73](https://github.com/jurassic73) +* Hardware Supported: ATmega32U4 Pro Micro +* Hardware Availability: see [Bill of Materials](https://github.com/jurassic73/split89#bill-of-materials). + + +Make example for this keyboard (after setting up your build environment): + + make handwired/split89: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). diff --git a/keyboards/handwired/split89/rules.mk b/keyboards/handwired/split89/rules.mk new file mode 100644 index 000000000000..9b916f556e50 --- /dev/null +++ b/keyboards/handwired/split89/rules.mk @@ -0,0 +1,24 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = caterina + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +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 +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = no # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output + +SPLIT_KEYBOARD = yes diff --git a/keyboards/handwired/split89/split89.c b/keyboards/handwired/split89/split89.c new file mode 100644 index 000000000000..8cceee9c591b --- /dev/null +++ b/keyboards/handwired/split89/split89.c @@ -0,0 +1,17 @@ +/* Copyright 2021 jurassic73 + * + * 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 "split89.h" diff --git a/keyboards/handwired/split89/split89.h b/keyboards/handwired/split89/split89.h new file mode 100644 index 000000000000..d04f0296d79a --- /dev/null +++ b/keyboards/handwired/split89/split89.h @@ -0,0 +1,50 @@ +/* Copyright 2021 jurassic73 + * + * 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" + +/* This is a shortcut to help you visually see your layout. + * + * The first section contains all of the arguments representing the physical + * layout of the board and position of the keys minus blanks in the matrix. + * + * The second converts the arguments into a two-dimensional array which + * represents the switch matrix which includes blanks in the wired out matrix. + */ +#define LAYOUT( \ + k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k10, k11, k12, k13, k14, k15, \ + k16, k17, k18, k19, k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k30, k31, \ + k32, k33, k34, k35, k36, k37, k38, k39, k40, k41, k42, k43, k44, k45, k46, k47, \ + k48, k49, k50, k51, k52, k53, k54, k55, k56, k57, k58, k59, k60, \ + k61, k62, k63, k64, k65, k66, k67, k68, k69, k70, k71, k72, k73, \ + k74, k75, k76, k77, k78, k79, k80, k81, k82, k83, k84, k85, k86, k87, k88 \ + ) \ + { \ + { KC_NO, KC_NO, KC_NO, KC_NO, k00, k01, k02, k03, k04, k05 }, \ + { KC_NO, KC_NO, KC_NO, KC_NO, k16, k17, k18, k19, k20, k21 }, \ + { KC_NO, KC_NO, KC_NO, KC_NO, k32, k33, k34, k35, k36, k37 }, \ + { KC_NO, KC_NO, KC_NO, KC_NO, k48, k49, k50, k51, k52, k53 }, \ + { KC_NO, KC_NO, KC_NO, KC_NO, k61, k62, k63, k64, k65, k66, }, \ + { KC_NO, KC_NO, KC_NO, KC_NO, k74, k75, k76, k77, k78, k79, }, \ + { k06, k07, k08, k09, k10, k11, k12, k13, k14, k15 }, \ + { k22, k23, k24, k25, k26, k27, k28, k29, k30, k31 }, \ + { k38, k39, k40, k41, k42, k43, k44, k45, k46, k47 }, \ + { k54, k55, k56, k57, k58, k59, k60, KC_NO, KC_NO, KC_NO }, \ + { k67, k68, k69, k70, k71, KC_NO, k72, KC_NO, k73, KC_NO }, \ + { k80, k81, KC_NO, k82, k83, k84, k85, k86, k87, k88 } \ +} diff --git a/keyboards/kbdfans/kbd67/rev2/info.json b/keyboards/kbdfans/kbd67/rev2/info.json index 3bb41a029bb1..b5cc7965440d 100644 --- a/keyboards/kbdfans/kbd67/rev2/info.json +++ b/keyboards/kbdfans/kbd67/rev2/info.json @@ -386,6 +386,81 @@ {"x":14, "y":4}, {"x":15, "y":4}] }, + "LAYOUT_65_ansi_split_bs_2_right_mods": { + "layout": [ + {"x":0, "y":0}, + {"x":1, "y":0}, + {"x":2, "y":0}, + {"x":3, "y":0}, + {"x":4, "y":0}, + {"x":5, "y":0}, + {"x":6, "y":0}, + {"x":7, "y":0}, + {"x":8, "y":0}, + {"x":9, "y":0}, + {"x":10, "y":0}, + {"x":11, "y":0}, + {"x":12, "y":0}, + {"x":13, "y":0}, + {"x":14, "y":0}, + {"x":15, "y":0}, + + {"x":0, "y":1, "w":1.5}, + {"x":1.5, "y":1}, + {"x":2.5, "y":1}, + {"x":3.5, "y":1}, + {"x":4.5, "y":1}, + {"x":5.5, "y":1}, + {"x":6.5, "y":1}, + {"x":7.5, "y":1}, + {"x":8.5, "y":1}, + {"x":9.5, "y":1}, + {"x":10.5, "y":1}, + {"x":11.5, "y":1}, + {"x":12.5, "y":1}, + {"x":13.5, "y":1, "w":1.5}, + {"x":15, "y":1}, + + {"x":0, "y":2, "w":1.75}, + {"x":1.75, "y":2}, + {"x":2.75, "y":2}, + {"x":3.75, "y":2}, + {"x":4.75, "y":2}, + {"x":5.75, "y":2}, + {"x":6.75, "y":2}, + {"x":7.75, "y":2}, + {"x":8.75, "y":2}, + {"x":9.75, "y":2}, + {"x":10.75, "y":2}, + {"x":11.75, "y":2}, + {"x":12.75, "y":2, "w":2.25}, + {"x":15, "y":2}, + + {"x":0, "y":3, "w":2.25}, + {"x":2.25, "y":3}, + {"x":3.25, "y":3}, + {"x":4.25, "y":3}, + {"x":5.25, "y":3}, + {"x":6.25, "y":3}, + {"x":7.25, "y":3}, + {"x":8.25, "y":3}, + {"x":9.25, "y":3}, + {"x":10.25, "y":3}, + {"x":11.25, "y":3}, + {"x":12.25, "y":3, "w":1.75}, + {"x":14, "y":3}, + {"x":15, "y":3}, + + {"x":0, "y":4, "w":1.25}, + {"x":1.25, "y":4, "w":1.25}, + {"x":2.5, "y":4, "w":1.25}, + {"x":3.75, "y":4, "w":6.25}, + {"x":10, "y":4, "w":1.5}, + {"x":11.5, "y":4, "w":1.5}, + {"x":13, "y":4}, + {"x":14, "y":4}, + {"x":15, "y":4}] + }, "LAYOUT_65_iso": { "layout": [ {"x":0, "y":0}, diff --git a/keyboards/kbdfans/kbd67/rev2/keymaps/rouge8/keymap.c b/keyboards/kbdfans/kbd67/rev2/keymaps/rouge8/keymap.c index a867cff23279..023646acac36 100644 --- a/keyboards/kbdfans/kbd67/rev2/keymaps/rouge8/keymap.c +++ b/keyboards/kbdfans/kbd67/rev2/keymaps/rouge8/keymap.c @@ -26,15 +26,15 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * |----------------------------------------------------------------| * |Shift | Z| X| C| V| B| N| M| , | . | / |Shift | ↑ |PgDn| * |----------------------------------------------------------------| - * |Ctrl|Alt |GUI | Space |GUI |FN|Ctrl| ← | ↓ | →  | + * |Ctrl|Alt |GUI | Space |GUI |FN | ← | ↓ | →  | * `----------------------------------------------------------------' */ -[0] = LAYOUT_65_ansi_split_bs( +[0] = LAYOUT_65_ansi_split_bs_2_right_mods( 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_GRV, KC_BSLS, KC_HOME, 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_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_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_LALT, KC_LGUI, KC_SPC, KC_RGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_RGUI, MO(1), KC_LEFT, KC_DOWN, KC_RGHT ), /* Keymap Fn Layer @@ -47,14 +47,14 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { * |----------------------------------------------------------------| * | | | | | | | | |End|PDn|Dow| | |Vol-| * |----------------------------------------------------------------| - * | | | | | | | |Prv|Ply|Nxt | + * | | | | | | |Prv|Ply|Nxt | * `----------------------------------------------------------------' */ -[1] = LAYOUT_65_ansi_split_bs( +[1] = LAYOUT_65_ansi_split_bs_2_right_mods( 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_INS, \ _______,_______, KC_UP,_______,_______,_______,_______,_______,KC_PSCR,KC_SLCK,KC_PAUS, KC_UP,_______, _______,_______, \ _______,KC_LEFT,KC_DOWN,KC_RGHT,_______,_______,_______,_______,KC_HOME,KC_PGUP,KC_LEFT,KC_RGHT, _______,KC_VOLU, \ _______,_______,_______,_______,_______,_______,_______,_______, KC_END,KC_PGDN,KC_DOWN, _______,_______,KC_VOLD, \ - _______, _______, _______, _______, _______,_______,_______,KC_MPRV,KC_MPLY,KC_MNXT), + _______, _______, _______, _______, _______,_______,KC_MPRV,KC_MPLY,KC_MNXT), }; diff --git a/keyboards/kbdfans/kbd67/rev2/rev2.h b/keyboards/kbdfans/kbd67/rev2/rev2.h index 924c68572152..1c1c0bf41809 100644 --- a/keyboards/kbdfans/kbd67/rev2/rev2.h +++ b/keyboards/kbdfans/kbd67/rev2/rev2.h @@ -70,7 +70,7 @@ { K40, K41, KC_NO, K43, KC_NO, KC_NO, K46, KC_NO, KC_NO, KC_NO, K4A, K4B, KC_NO, K4D, K4E, K4F }, \ } -#define LAYOUT_65_ansi_blocker_splitbs( \ +#define LAYOUT_65_ansi_blocker_split_bs( \ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ K10, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, K1F, \ K20, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K2F, \ @@ -85,8 +85,6 @@ { K40, K41, KC_NO, K43, KC_NO, KC_NO, K46, KC_NO, KC_NO, KC_NO, K4A, K4B, KC_NO, K4D, K4E, K4F }, \ } -#define LAYOUT_65_ansi_blocker_split_bs LAYOUT_65_ansi_blocker_splitbs - #define LAYOUT_65_ansi_split_bs( \ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ K10, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, K1F, \ @@ -102,6 +100,21 @@ { K40, K41, KC_NO, K43, KC_NO, KC_NO, K46, KC_NO, KC_NO, KC_NO, K4A, K4B, K4C, K4D, K4E, K4F }, \ } +#define LAYOUT_65_ansi_split_bs_2_right_mods( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ + K10, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, K1F, \ + K20, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K2F, \ + K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, K3E, K3F, \ + K40, K41, K43, K46, K4A, K4B, K4D, K4E, K4F \ +) \ +{ \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F }, \ + { K10, KC_NO, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, K1F }, \ + { K20, KC_NO, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, KC_NO, K2F }, \ + { K30, KC_NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, KC_NO, K3D, K3E, K3F }, \ + { K40, K41, KC_NO, K43, KC_NO, KC_NO, K46, KC_NO, KC_NO, KC_NO, K4A, KC_NO, K4B, K4D, K4E, K4F }, \ +} + #define LAYOUT_65_iso( \ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0E, K0F, \ K10, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1F, \ @@ -131,3 +144,5 @@ { K30, KC_NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, KC_NO, K3D, K3E, K3F }, \ { K40, K41, KC_NO, K43, K44, KC_NO, K46, KC_NO, K48, KC_NO, K4A, K4B, K4C, K4D, K4E, K4F }, \ } + +#define LAYOUT_65_ansi_blocker_splitbs LAYOUT_65_ansi_blocker_split_bs diff --git a/keyboards/keebio/iris/keymaps/compilation-error/config.h b/keyboards/keebio/iris/keymaps/compilation-error/config.h new file mode 100644 index 000000000000..149a54be7fa3 --- /dev/null +++ b/keyboards/keebio/iris/keymaps/compilation-error/config.h @@ -0,0 +1,21 @@ +/* +Copyright 2017 Danny Nguyen + +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 USE_I2C +#define EE_HANDS diff --git a/keyboards/keebio/iris/keymaps/compilation-error/keymap.c b/keyboards/keebio/iris/keymaps/compilation-error/keymap.c new file mode 100644 index 000000000000..1b3f1146074e --- /dev/null +++ b/keyboards/keebio/iris/keymaps/compilation-error/keymap.c @@ -0,0 +1,149 @@ + /* Copyright 2021 Romeet Chhabra + * + * 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 custom_layers { + _QWERTY, + _LOWER, + _RAISE, + _ADJUST, +}; + +enum custom_keycodes { + QWERTY = SAFE_RANGE, + LOWER, + RAISE, + ADJUST, +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [_QWERTY] = LAYOUT( + //┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐ + 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_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + LALT_T(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_LSPO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_MUTE, KC_PSCR, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSPC, + //└────────┴────────┴────────┴───┬────┴───┬────┴───┬────┴───┬────┘ └───┬────┴───┬────┴───┬────┴───┬────┴────────┴────────┴────────┘ + KC_LGUI, LOWER, KC_SPC, KC_ENT, RAISE, KC_LCTL + // └────────┴────────┴────────┘ └────────┴────────┴────────┘ + ), + + [_LOWER] = LAYOUT( + //┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐ + RGB_TOG, _______, KC_BTN3, _______, KC_LBRC, KC_RBRC, KC_EQL, KC_P7, KC_P8, KC_P9, KC_PSLS, KC_DEL, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_BTN4, KC_BTN1, KC_MS_U, KC_BTN2, KC_LCBR, KC_RCBR, KC_PLUS, KC_P4, KC_P5, KC_P6, KC_PAST, _______, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_BTN5, KC_MS_L, KC_MS_D, KC_MS_R, KC_LT, KC_GT, KC_MINS, KC_P1, KC_P2, KC_P3, KC_PMNS, _______, + //├────────┼────────┼────────┼────────┼────────┼────────┼────────┐ ┌────────┼────────┼────────┼────────┼────────┼────────┼────────┤ + _______, _______, _______, _______, _______, _______, _______, _______, KC_UNDS, KC_P0, KC_PDOT, KC_PENT, KC_PPLS, _______, + //└────────┴────────┴────────┴───┬────┴───┬────┴───┬────┴───┬────┘ └───┬────┴───┬────┴───┬────┴───┬────┴────────┴────────┴────────┘ + _______, _______, _______, _______, MO(_ADJUST), _______ + // └────────┴────────┴────────┘ └────────┴────────┴────────┘ + ), + + [_RAISE] = LAYOUT( + //┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐ + KC_F12, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + _______, _______, _______, _______, _______, _______, KC_LBRC, KC_LCBR, KC_LT, KC_GT, KC_RCBR, KC_RBRC, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + _______, _______, _______, _______, _______, _______, KC_PGUP, KC_MINS, KC_UNDS, KC_EQL, KC_PLUS, KC_PGDN, + //├────────┼────────┼────────┼────────┼────────┼────────┼────────┐ ┌────────┼────────┼────────┼────────┼────────┼────────┼────────┤ + _______, _______, _______, _______, _______, _______, _______, _______, KC_HOME, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_END, + //└────────┴────────┴────────┴───┬────┴───┬────┴───┬────┴───┬────┘ └───┬────┴───┬────┴───┬────┴───┬────┴────────┴────────┴────────┘ + _______, MO(_ADJUST), _______, _______, _______, _______ + // └────────┴────────┴────────┘ └────────┴────────┴────────┘ + ), + + [_ADJUST] = LAYOUT( + //┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐ + KC_F12, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + RGB_TOG, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, _______, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + RGB_MOD, KC_MPRV, KC_MNXT, KC_VOLU, KC_PGUP, KC_UNDS, KC_EQL, KC_HOME, RGB_HUI, RGB_SAI, RGB_VAI, _______, + //├────────┼────────┼────────┼────────┼────────┼────────┼────────┐ ┌────────┼────────┼────────┼────────┼────────┼────────┼────────┤ + KC_MUTE, KC_MSTP, KC_MPLY, KC_VOLD, KC_PGDN, KC_MINS, RESET, EEP_RST, KC_PLUS, KC_END, RGB_HUD, RGB_SAD, RGB_VAD, _______, + //└────────┴────────┴────────┴───┬────┴───┬────┴───┬────┴───┬────┘ └───┬────┴───┬────┴───┬────┴───┬────┴────────┴────────┴────────┘ + _______, _______, _______, _______, _______, _______ + // └────────┴────────┴────────┘ └────────┴────────┴────────┘ + ) +}; + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case QWERTY: + if (record->event.pressed) { + set_single_persistent_default_layer(_QWERTY); + } + return false; + break; + case LOWER: + if (record->event.pressed) { + layer_on(_LOWER); + update_tri_layer(_LOWER, _RAISE, _ADJUST); + } else { + layer_off(_LOWER); + update_tri_layer(_LOWER, _RAISE, _ADJUST); + } + return false; + break; + case RAISE: + if (record->event.pressed) { + layer_on(_RAISE); + update_tri_layer(_LOWER, _RAISE, _ADJUST); + } else { + layer_off(_RAISE); + update_tri_layer(_LOWER, _RAISE, _ADJUST); + } + return false; + break; + case ADJUST: + if (record->event.pressed) { + layer_on(_ADJUST); + } else { + layer_off(_ADJUST); + } + return false; + break; + } + return true; +} + +bool encoder_update_user(uint8_t index, bool clockwise) { + if (index == 0) { + if (clockwise) { + tap_code(KC_VOLU); + } else { + tap_code(KC_VOLD); + } + } + else if (index == 1) { + if (clockwise) { + tap_code(KC_WH_D); + } else { + tap_code(KC_WH_U); + } + } + return true; +} diff --git a/keyboards/keebio/iris/keymaps/compilation-error/rules.mk b/keyboards/keebio/iris/keymaps/compilation-error/rules.mk new file mode 100644 index 000000000000..b0c1afe096e0 --- /dev/null +++ b/keyboards/keebio/iris/keymaps/compilation-error/rules.mk @@ -0,0 +1 @@ +MOUSEKEY_ENABLE = yes # Mouse keys diff --git a/keyboards/keebio/iris/keymaps/mnil/config.h b/keyboards/keebio/iris/keymaps/mnil/config.h new file mode 100644 index 000000000000..091df08eff28 --- /dev/null +++ b/keyboards/keebio/iris/keymaps/mnil/config.h @@ -0,0 +1,29 @@ +/* Copyright 2021 Mats Nilsson + * + * 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 EE_HANDS + +#undef RGBLED_NUM +#define RGBLIGHT_ANIMATIONS +#define RGBLED_NUM 12 +#define RGBLIGHT_HUE_STEP 8 +#define RGBLIGHT_SAT_STEP 8 +#define RGBLIGHT_VAL_STEP 8 +#define RGBLIGHT_SPLIT \ + { 6, 6 } +#define RGBLIGHT_SLEEP diff --git a/keyboards/keebio/iris/keymaps/mnil/keymap.c b/keyboards/keebio/iris/keymaps/mnil/keymap.c new file mode 100644 index 000000000000..7c7dc1a40d66 --- /dev/null +++ b/keyboards/keebio/iris/keymaps/mnil/keymap.c @@ -0,0 +1,94 @@ +/* Copyright 2021 Mats Nilsson + * + * 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 "mnil.h" + +const uint8_t RGBLED_BREATHING_INTERVALS[] PROGMEM = {5, 5, 5, 5}; + +#define HSV_DEFAULT 32, 255, 255 + +layer_state_t layer_state_set_user(layer_state_t state) { + state = update_tri_layer_state(state, _SYMBOLS, _NAVIGATION, _NUMPAD); + + switch (get_highest_layer(state)) { + case _NUMPAD: + rgblight_sethsv_noeeprom(HSV_GREEN); + break; + case _NAVIGATION: + rgblight_sethsv_noeeprom(HSV_MAGENTA); + break; + case _SYMBOLS: + rgblight_sethsv_noeeprom(HSV_AZURE); + break; + default: // for any other layers, or the default layer + rgblight_sethsv_noeeprom(HSV_DEFAULT); + break; + } + return state; +} + +// clang-format off +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_COLEMAK] = LAYOUT( + //┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐ + KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_B, KC_J, KC_L, KC_U, KC_Y, TD(OAA), KC_NO, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_LSFT, TD(AAE), KC_R, KC_S, KC_T, KC_G, KC_M, KC_N, KC_E, KC_I, KC_O, KC_NO, + //├────────┼────────┼────────┼────────┼────────┼────────┼────────┐ ┌────────┼────────┼────────┼────────┼────────┼────────┼────────┤ + KC_LCTL, KC_Z, KC_X, KC_C, KC_D, KC_V, _NAV_SPC, _SYM_ENT,KC_K, KC_H, KC_COMM, KC_DOT, SE_MINS, KC_LGUI, + //└────────┴────────┴────────┴───┬────┴───┬────┴───┬────┴───┬────┘ └───┬────┴───┬────┴───┬────┴───┬────┴────────┴────────┴────────┘ + KC_LGUI, SFT_TAB, _NAV_SPC, _SYM_ENT,CTL_BSPC,ALT_DEL), + // └────────┴────────┴────────┘ └────────┴────────┴────────┘ + [_SYMBOLS] = LAYOUT( + //┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐ + KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_TRNS, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TRNS, KC_NO, SE_PIPE, SE_LBRC, SE_RBRC, KC_NO, S(KC_5), SE_QUES, SE_AT, SE_EQL, SE_DLR, KC_TRNS, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TRNS, SE_LCBR, SE_RCBR, SE_LPRN, SE_RPRN, KC_NO, SE_PLUS, S(KC_1), S(KC_2), S(KC_3), SE_AMPR, KC_TRNS, + //├────────┼────────┼────────┼────────┼────────┼────────┼────────┐ ┌────────┼────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TRNS, M_TILD, M_CIRC, SE_LESS, SE_GRTR, KC_NO, KC_TRNS, KC_TRNS, SE_APOS, SE_SLSH, SE_BSLS, SE_ASTR, M_BTCK, KC_TRNS, + //└────────┴────────┴────────┴───┬────┴───┬────┴───┬────┴───┬────┘ └───┬────┴───┬────┴───┬────┴───┬────┴────────┴────────┴────────┘ + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS ), + // └────────┴────────┴────────┘ └────────┴────────┴────────┘ + [_NAVIGATION] = 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_NO, CUT, COPY, PASTE, AUTOFILL, KC_NO, KC_HOME, KC_WH_D, KC_WH_U, KC_END, KC_NO, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TRNS, KC_ACL0, KC_ACL1, KC_BTN2, KC_BTN1, KC_LCTL, KC_WH_L, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R, KC_WH_R, + //├────────┼────────┼────────┼────────┼────────┼────────┼────────┐ ┌────────┼────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TRNS, KC_ACL2, KC_BTN4, KC_BTN3, KC_BTN5, KC_NO, KC_TRNS, KC_TRNS, KC_NO, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_LCTL, + //└────────┴────────┴────────┴───┬────┴───┬────┴───┬────┴───┬────┘ └───┬────┴───┬────┴───┬────┴───┬────┴────────┴────────┴────────┘ + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS ), + // └────────┴────────┴────────┘ └────────┴────────┴────────┘ + [_NUMPAD] = LAYOUT( + //┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐ + RGB_TOG, RGB_M_P, RGB_M_B, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, RESET, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TRNS, QUIT, WIN, MVWSL , MVWSR, CRYWS, TERM, KC_7, KC_8, KC_9, KC_COMM, KC_NO, + //├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TRNS, CS_TAB, C_TAB, PRVWS, NXTWS, I3MOD, OPEN, KC_4, KC_5, KC_6, KC_0, KC_NO, + //├────────┼────────┼────────┼────────┼────────┼────────┼────────┐ ┌────────┼────────┼────────┼────────┼────────┼────────┼────────┤ + KC_TRNS, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, MOVWS, KC_TRNS, KC_TRNS, BROWSER, KC_1, KC_2, KC_3, KC_DOT, KC_NO, + //└────────┴────────┴────────┴───┬────┴───┬────┴───┬────┴───┬────┘ └───┬────┴───┬────┴───┬────┴───┬────┴────────┴────────┴────────┘ + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS ), + // └────────┴────────┴────────┘ └────────┴────────┴────────┘ +}; +// clang-format on diff --git a/keyboards/keebio/iris/keymaps/mnil/readme.md b/keyboards/keebio/iris/keymaps/mnil/readme.md new file mode 100644 index 000000000000..e74eea471565 --- /dev/null +++ b/keyboards/keebio/iris/keymaps/mnil/readme.md @@ -0,0 +1,2 @@ +# mnil's iris keymap +Read my user settings [here](../../../../../users/mnil/readme.md) for more details. diff --git a/keyboards/keebio/iris/keymaps/mnil/rules.mk b/keyboards/keebio/iris/keymaps/mnil/rules.mk new file mode 100644 index 000000000000..22e6c8fccc8c --- /dev/null +++ b/keyboards/keebio/iris/keymaps/mnil/rules.mk @@ -0,0 +1 @@ +RGBLIGHT_ENABLE = yes diff --git a/keyboards/kmac_pad/config.h b/keyboards/kmac_pad/config.h new file mode 100644 index 000000000000..eb33a994b3da --- /dev/null +++ b/keyboards/kmac_pad/config.h @@ -0,0 +1,102 @@ +/* +Copyright 2021 talsu + +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 "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x4B4D // KM +#define PRODUCT_ID 0x4143 // AC +#define DEVICE_VER 0x0104 +#define MANUFACTURER KBDMania +#define PRODUCT KMAC PAD + +/* key matrix size */ +#define MATRIX_ROWS 6 +#define MATRIX_COLS 4 + +/* + * Keyboard Matrix Assignments + * The KMAC uses demultiplexers for the cols, they are only included here as documentation. + * See matrix.c for more details. + */ +#define MATRIX_ROW_PINS { E2, D0, D1, D2, D3, D5 } +#define MATRIX_COL_PINS { C7, C6, B6, B5 } +#define UNUSED_PINS + +/* COL2ROW, ROW2COL*/ +// #define DIODE_DIRECTION COL2ROW + +// #define LED_CAPS_LOCK_PIN B0 +// #define LED_SCROLL_LOCK_PIN E6 +// #define LED_PIN_ON_STATE 0 + +/* number of backlight levels */ +// #define BACKLIGHT_LEVELS 3 +// #define BACKLIGHT_PIN B7 +// #define BACKLIGHT_BREATHING + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* define if matrix has ghost (lacks anti-ghosting diodes) */ +//#define MATRIX_HAS_GHOST + +/* 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 + +/* + * Force NKRO + * + * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved + * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the + * makefile for this to work.) + * + * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N) + * until the next keyboard reset. + * + * NKRO may prevent your keystrokes from being detected in the BIOS, but it is + * fully operational during normal computer usage. + * + * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N) + * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by + * bootmagic, NKRO mode will always be enabled until it is toggled again during a + * power-up. + * + */ +//#define FORCE_NKRO + +/* + * Feature disable options + * These options are also useful to firmware size reduction. + */ + +/* disable debug print */ +//#define NO_DEBUG + +/* disable print */ +//#define NO_PRINT + +/* disable action features */ +//#define NO_ACTION_LAYER +//#define NO_ACTION_TAPPING +//#define NO_ACTION_ONESHOT +//#define NO_ACTION_MACRO +//#define NO_ACTION_FUNCTION diff --git a/keyboards/kmac_pad/info.json b/keyboards/kmac_pad/info.json new file mode 100644 index 000000000000..6a17b3d452a0 --- /dev/null +++ b/keyboards/kmac_pad/info.json @@ -0,0 +1,35 @@ +{ + "keyboard_name": "KMAC PAD", + "maintainer": "talsu", + "width": 4, + "height": 6.5, + "layouts": { + "LAYOUT": { + "layout": [ + {"label":"K00", "x":3, "y":0}, + + {"label":"K10", "x":0, "y":1.25}, + {"label":"K11", "x":1, "y":1.25}, + {"label":"K12", "x":2, "y":1.25}, + {"label":"K13", "x":3, "y":1.25}, + + {"label":"K20", "x":0, "y":2.25}, + {"label":"K21", "x":1, "y":2.25}, + {"label":"K22", "x":2, "y":2.25}, + {"label":"K23", "x":3, "y":2.25, "h":2}, + + {"label":"K30", "x":0, "y":3.25}, + {"label":"K31", "x":1, "y":3.25}, + {"label":"K32", "x":2, "y":3.25}, + + {"label":"K40", "x":0, "y":4.25}, + {"label":"K41", "x":1, "y":4.25}, + {"label":"K42", "x":2, "y":4.25}, + {"label":"K43", "x":3, "y":4.25, "h":2}, + + {"label":"K50", "x":0, "y":5.25, "w":2}, + {"label":"K52", "x":2, "y":5.25} + ] + } + } +} diff --git a/keyboards/kmac_pad/keymaps/default/keymap.c b/keyboards/kmac_pad/keymaps/default/keymap.c new file mode 100644 index 000000000000..b9b9f823fb4f --- /dev/null +++ b/keyboards/kmac_pad/keymaps/default/keymap.c @@ -0,0 +1,143 @@ +/* +Copyright 2021 talsu + +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 kmac_pad_keycodes { + MD_BOOT = SAFE_RANGE, + MCR1, + MCR2, + MCR3, + MCR4, + MCR5, + MCR6, + MCR7, + MCR8, + MCR9, + MCR10, + MCR11, + MCR12 +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT( /* Base */ + TG(1), + KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + KC_P7, KC_P8, KC_P9, KC_PPLS, + KC_P4, KC_P5, KC_P6, + KC_P1, KC_P2, KC_P3, KC_PENT, + KC_P0, KC_PDOT ), + [1] = LAYOUT( /* FN */ + KC_TRNS, + MCR1, MCR2, MCR3, KC_TRNS, + MCR4, MCR5, MCR6, KC_TRNS, + MCR7, MCR8, MCR9, + MCR10, MCR11, MCR12, KC_TRNS, + KC_TRNS, MD_BOOT ) +}; + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + + switch (keycode) { + case MD_BOOT: + { + static uint32_t key_timer; + if (record->event.pressed) { + key_timer = timer_read32(); + } else { + if (timer_elapsed32(key_timer) >= 2000) { + reset_keyboard(); + } + } + return false; + } + case MCR1: + if (record->event.pressed) { + SEND_STRING("Macro 1"); + } + return false; + case MCR2: + if (record->event.pressed) { + SEND_STRING("Macro 2"); + } + return false; + case MCR3: + if (record->event.pressed) { + SEND_STRING("Macro 3"); + } + return false; + case MCR4: + if (record->event.pressed) { + SEND_STRING("Macro 4"); + } + return false; + case MCR5: + if (record->event.pressed) { + SEND_STRING("Macro 5"); + } + return false; + case MCR6: + if (record->event.pressed) { + SEND_STRING("Macro 6"); + } + return false; + case MCR7: + if (record->event.pressed) { + SEND_STRING("Macro 7"); + } + return false; + case MCR8: + if (record->event.pressed) { + SEND_STRING("Macro 8"); + } + return false; + case MCR9: + if (record->event.pressed) { + SEND_STRING("Macro 9"); + } + return false; + case MCR10: + if (record->event.pressed) { + SEND_STRING("Macro 10"); + } + return false; + case MCR11: + if (record->event.pressed) { + SEND_STRING("Macro 12"); + } + return false; + case MCR12: + if (record->event.pressed) { + SEND_STRING("Macro 12"); + } + return false; + default: + return true; + } + +} + +bool led_update_user(led_t led_state) { + writePin(B1, led_state.num_lock); + return false; +} + + +layer_state_t layer_state_set_user(layer_state_t state) { + writePin(B3, !IS_LAYER_ON_STATE(state, 0)); + return state; +} diff --git a/keyboards/kmac_pad/keymaps/default/readme.md b/keyboards/kmac_pad/keymaps/default/readme.md new file mode 100644 index 000000000000..3b9b739a2ad8 --- /dev/null +++ b/keyboards/kmac_pad/keymaps/default/readme.md @@ -0,0 +1,61 @@ +# The default keymap for KMAC PAD + +This is the default keymap. It implements the same features as the official default KMAC PAD firmware. + +## Layers + +The keymap has two layers. Press the 'FN' key to toggle the Default layer and Function layer. + +### Layer 1: Default Layer + + ,---. + |TG1| + `---' + ,---------------. + |NUM| / | * | - | + |---------------| + | 7 | 8 | 9 | | + |-----------| + | + | 4 | 5 | 6 | | + |---------------| + | 1 | 2 | 3 | | + |-----------|Ent| + | 0 | . | | + '---------------' + +### Layer 2: Function Layer + + ,---. + |TG1| + `---' + ,---------------. + |M1 |M2 |M3 | | + |---------------| + |M4 |M5 |M6 | | + |-----------| | + |M7 |M8 |M9 | | + |---------------| + |M10|M11|M12| | + |-----------| | + | | | | + '---------------' + +## Macros + +The default macro is typed with meaningless strings that exist as samples. + + +| Macro | Action | +|:-----:| -------------------------------------- | +| 1 | Types `Macro 1` | +| 2 | Types `Macro 2` | +| 3 | Types `Macro 3` | +| 4 | Types `Macro 4` | +| 5 | Types `Macro 5` | +| 6 | Types `Macro 6` | +| 7 | Types `Macro 7` | +| 8 | Types `Macro 8` | +| 9 | Types `Macro 9` | +| 10 | Types `Macro 10` | +| 11 | Types `Macro 11` | +| 12 | Types `Macro 12` | diff --git a/keyboards/kmac_pad/kmac_pad.c b/keyboards/kmac_pad/kmac_pad.c new file mode 100644 index 000000000000..87083668cc74 --- /dev/null +++ b/keyboards/kmac_pad/kmac_pad.c @@ -0,0 +1,29 @@ +/* +Copyright 2021 talsu + +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 "kmac_pad.h" + +void keyboard_pre_init_kb(void) { + + /* Set Backlight pin as output + * FN Pin PB3 + * PAD Pin PB1 + */ + setPinOutput(B3); + setPinOutput(B1); + keyboard_pre_init_user(); +} diff --git a/keyboards/kmac_pad/kmac_pad.h b/keyboards/kmac_pad/kmac_pad.h new file mode 100644 index 000000000000..99796083390f --- /dev/null +++ b/keyboards/kmac_pad/kmac_pad.h @@ -0,0 +1,37 @@ +/* +Copyright 2021 talsu + +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, K11, K12, K13, \ + K20, K21, K22, K23, \ + K30, K31, K32, \ + K40, K41, K42, K43, \ + K50, K52 \ +) \ +{ \ + { K00, KC_NO, KC_NO, KC_NO }, \ + { K10, K11, K12, K13 }, \ + { K20, K21, K22, K23 }, \ + { K30, K31, K32, KC_NO }, \ + { K40, K41, K42, K43 }, \ + { K50, KC_NO, K52, KC_NO } \ +} diff --git a/keyboards/kmac_pad/matrix.c b/keyboards/kmac_pad/matrix.c new file mode 100644 index 000000000000..476e40f51441 --- /dev/null +++ b/keyboards/kmac_pad/matrix.c @@ -0,0 +1,111 @@ +/* +Copyright 2021 talsu + +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 "wait.h" +#include "matrix.h" +#include "quantum.h" + +static const pin_t row_pins[MATRIX_ROWS] = MATRIX_ROW_PINS; +static const pin_t col_pins[MATRIX_COLS] = MATRIX_COL_PINS; + +/* Columns 0 - 3 + * col / pin: + * 0: C7 + * 1: C6 + * 2: B6 + * 3: B5 + */ +static void unselect_cols(void) { + for (uint8_t col = 0; col < MATRIX_COLS; col++) { + setPinOutput(col_pins[col]); + writePinLow(col_pins[col]); + } +} + +static void select_col(uint8_t col) { + writePinHigh(col_pins[col]); +} + +static bool read_rows_on_col(matrix_row_t current_matrix[], uint8_t current_col) { + bool matrix_changed = false; + + // Select col and wait for col selecton to stabilize + select_col(current_col); + wait_us(30); + + // row:0 , col:0 FN key is DIRECT_PIN + if (current_col == 0) { + + matrix_row_t last_row_value = current_matrix[0]; + if (readPin(row_pins[0]) == 0) { + // Pin LO, set col bit + current_matrix[0] |= (1 << current_col); + } else { + // Pin HI, clear col bit + current_matrix[0] &= ~(1 << current_col); + } + + // Determine if the matrix changed state + if ((last_row_value != current_matrix[0]) && !(matrix_changed)) { + matrix_changed = true; + } + } + + // other row use MATRIX + for (uint8_t row_index = 1; row_index < MATRIX_ROWS; row_index++) { + + matrix_row_t last_row_value = current_matrix[row_index]; + if (readPin(row_pins[row_index]) == 0) { + // Pin HI, clear col bit + current_matrix[row_index] &= ~(1 << current_col); + } else { + // Pin LO, set col bit + current_matrix[row_index] |= (1 << current_col); + } + + // Determine if the matrix changed state + if ((last_row_value != current_matrix[row_index]) && !(matrix_changed)) { + matrix_changed = true; + } + } + + + // Unselect cols + unselect_cols(); + + return matrix_changed; +} + +void matrix_init_custom(void) { + // initialize hardware and global matrix state here + unselect_cols(); + + // initialize key pins + for (uint8_t row_index = 0; row_index < MATRIX_ROWS; row_index++) { + setPinInputHigh(row_pins[row_index]); + } +} + +bool matrix_scan_custom(matrix_row_t current_matrix[]) { + bool changed = false; + + for (uint8_t current_col = 0; current_col < MATRIX_COLS; current_col++) { + changed |= read_rows_on_col(current_matrix, current_col); + } + + return changed; +} diff --git a/keyboards/kmac_pad/readme.md b/keyboards/kmac_pad/readme.md new file mode 100644 index 000000000000..7605501f3a52 --- /dev/null +++ b/keyboards/kmac_pad/readme.md @@ -0,0 +1,56 @@ +# KMAC PAD + +![kmac_pad](https://i.imgur.com/4P1ybgNl.jpg) + +KMAC PAD is a num pad keyboard. +It can be used independently, but can also be used by connecting with KMAC keyboard case. + +* Keyboard Maintainer: [talsu](https://github.com/talsu) +* Hardware Supported: KMAC PAD +* Hardware Availability: http://www.kbdmania.net/xe/news/5232321 + +Make example for this keyboard (after setting up your build environment): + + make kmac_pad:default + +Flashing example for this keyboard: + + make kmac_pad: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 + +The PCB is hardwired to run the bootloader if the key at the `FN` position (the only key in first row) is held down when connecting the keyboard. + +## PCB + +![Imgur](https://i.imgur.com/ML66cvfl.jpg) +![Imgur](https://i.imgur.com/Kr2Wdtkl.jpg) + +### Switch Pins + +The FN key in the `Row 0` is directly connected to the E2 pin. +The rest of the rows below that use MATRIX. (`Row 1 ~ Row 5`) +| Row | Pin | +|:-----:| ---------------------- | +| 0 | x (Not in Matrix) | +| 1 | D0 | +| 2 | D1 | +| 3 | D2 | +| 4 | D3 | +| 5 | D5 | + +| Column | Pin | +|:------:| --------------------- | +| 0 | C7 | +| 1 | C6 | +| 2 | B6 | +| 3 | B5 | + +### Backlight Pins + +There are 2 pins for backlight. + +The LED of the FN key uses pin `B3`. +All other keys are connected to the `B1` pin. diff --git a/keyboards/kmac_pad/rules.mk b/keyboards/kmac_pad/rules.mk new file mode 100644 index 000000000000..3f63076c41e2 --- /dev/null +++ b/keyboards/kmac_pad/rules.mk @@ -0,0 +1,29 @@ +# MCU name +MCU = atmega32u4 + +# Processor frequency +F_CPU = 8000000 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration +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 +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output +CUSTOM_MATRIX = lite # Custom matrix file + +# Project specific files +SRC += matrix.c diff --git a/keyboards/kyria/kyria.h b/keyboards/kyria/kyria.h index de87c5ba514e..c1db6307e20a 100644 --- a/keyboards/kyria/kyria.h +++ b/keyboards/kyria/kyria.h @@ -17,6 +17,10 @@ #include "quantum.h" +#if defined(KEYBOARD_kyria_rev1) +# include "rev1.h" +#endif + /* This a shortcut to help you visually see your layout. * * The first section contains all of the arguments representing the physical @@ -25,58 +29,3 @@ * The second converts the arguments into a two-dimensional array which * represents the switch matrix. */ -#define LAYOUT( \ - L00, L01, L02, L03, L04, L05, R06, R07, R08, R09, R10, R11, \ - L12, L13, L14, L15, L16, L17, R18, R19, R20, R21, R22, R23, \ - L24, L25, L26, L27, L28, L29, L30, L31, R32, R33, R34, R35, R36, R37, R38, R39, \ - L40, L41, L42, L43, L44, R45, R46, R47, R48, R49 \ -) \ -{ \ - { KC_NO, KC_NO, L05, L04, L03, L02, L01, L00 }, \ - { KC_NO, KC_NO, L17, L16, L15, L14, L13, L12 }, \ - { L31, L30, L29, L28, L27, L26, L25, L24 }, \ - { L44, L43, L42, L41, L40, KC_NO, KC_NO, KC_NO }, \ - { KC_NO, KC_NO, R06, R07, R08, R09, R10, R11 }, \ - { KC_NO, KC_NO, R18, R19, R20, R21, R22, R23 }, \ - { R32, R33, R34, R35, R36, R37, R38, R39 }, \ - { R45, R46, R47, R48, R49, KC_NO, KC_NO, KC_NO }, \ -} - -#define LAYOUT_stack( \ - L00, L01, L02, L03, L04, L05, \ - L12, L13, L14, L15, L16, L17, \ - L24, L25, L26, L27, L28, L29, L30, L31, \ - L40, L41, L42, L43, L44, \ - \ - R06, R07, R08, R09, R10, R11, \ - R18, R19, R20, R21, R22, R23, \ - R32, R33, R34, R35, R36, R37, R38, R39, \ - R45, R46, R47, R48, R49 \ -) \ -{ \ - { KC_NO, KC_NO, L05, L04, L03, L02, L01, L00 }, \ - { KC_NO, KC_NO, L17, L16, L15, L14, L13, L12 }, \ - { L31, L30, L29, L28, L27, L26, L25, L24 }, \ - { L44, L43, L42, L41, L40, KC_NO, KC_NO, KC_NO }, \ - { KC_NO, KC_NO, R06, R07, R08, R09, R10, R11 }, \ - { KC_NO, KC_NO, R18, R19, R20, R21, R22, R23 }, \ - { R32, R33, R34, R35, R36, R37, R38, R39 }, \ - { R45, R46, R47, R48, R49, KC_NO, KC_NO, KC_NO }, \ -} - -#define LAYOUT_split_3x6_5( \ - L00, L01, L02, L03, L04, L05, R06, R07, R08, R09, R10, R11, \ - L12, L13, L14, L15, L16, L17, R18, R19, R20, R21, R22, R23, \ - L24, L25, L26, L27, L28, L29, R34, R35, R36, R37, R38, R39, \ - L40, L41, L42, L43, L44, R45, R46, R47, R48, R49 \ -) \ -{ \ - { KC_NO, KC_NO, L05, L04, L03, L02, L01, L00 }, \ - { KC_NO, KC_NO, L17, L16, L15, L14, L13, L12 }, \ - { KC_NO, KC_NO, L29, L28, L27, L26, L25, L24 }, \ - { L44, L43, L42, L41, L40, KC_NO, KC_NO, KC_NO }, \ - { KC_NO, KC_NO, R06, R07, R08, R09, R10, R11 }, \ - { KC_NO, KC_NO, R18, R19, R20, R21, R22, R23 }, \ - { KC_NO, KC_NO, R34, R35, R36, R37, R38, R39 }, \ - { R45, R46, R47, R48, R49, KC_NO, KC_NO, KC_NO }, \ -} diff --git a/keyboards/kyria/rev1/rev1.h b/keyboards/kyria/rev1/rev1.h index 2ef05bb0e98f..44060a153662 100644 --- a/keyboards/kyria/rev1/rev1.h +++ b/keyboards/kyria/rev1/rev1.h @@ -41,3 +41,42 @@ { R32, R33, R34, R35, R36, R37, R38, R39 }, \ { R45, R46, R47, R48, R49, KC_NO, KC_NO, KC_NO }, \ } + +#define LAYOUT_stack( \ + L00, L01, L02, L03, L04, L05, \ + L12, L13, L14, L15, L16, L17, \ + L24, L25, L26, L27, L28, L29, L30, L31, \ + L40, L41, L42, L43, L44, \ + \ + R06, R07, R08, R09, R10, R11, \ + R18, R19, R20, R21, R22, R23, \ + R32, R33, R34, R35, R36, R37, R38, R39, \ + R45, R46, R47, R48, R49 \ +) \ +{ \ + { KC_NO, KC_NO, L05, L04, L03, L02, L01, L00 }, \ + { KC_NO, KC_NO, L17, L16, L15, L14, L13, L12 }, \ + { L31, L30, L29, L28, L27, L26, L25, L24 }, \ + { L44, L43, L42, L41, L40, KC_NO, KC_NO, KC_NO }, \ + { KC_NO, KC_NO, R06, R07, R08, R09, R10, R11 }, \ + { KC_NO, KC_NO, R18, R19, R20, R21, R22, R23 }, \ + { R32, R33, R34, R35, R36, R37, R38, R39 }, \ + { R45, R46, R47, R48, R49, KC_NO, KC_NO, KC_NO }, \ +} + +#define LAYOUT_split_3x6_5( \ + L00, L01, L02, L03, L04, L05, R06, R07, R08, R09, R10, R11, \ + L12, L13, L14, L15, L16, L17, R18, R19, R20, R21, R22, R23, \ + L24, L25, L26, L27, L28, L29, R34, R35, R36, R37, R38, R39, \ + L40, L41, L42, L43, L44, R45, R46, R47, R48, R49 \ +) \ +{ \ + { KC_NO, KC_NO, L05, L04, L03, L02, L01, L00 }, \ + { KC_NO, KC_NO, L17, L16, L15, L14, L13, L12 }, \ + { KC_NO, KC_NO, L29, L28, L27, L26, L25, L24 }, \ + { L44, L43, L42, L41, L40, KC_NO, KC_NO, KC_NO }, \ + { KC_NO, KC_NO, R06, R07, R08, R09, R10, R11 }, \ + { KC_NO, KC_NO, R18, R19, R20, R21, R22, R23 }, \ + { KC_NO, KC_NO, R34, R35, R36, R37, R38, R39 }, \ + { R45, R46, R47, R48, R49, KC_NO, KC_NO, KC_NO }, \ +} diff --git a/keyboards/kyria/rules.mk b/keyboards/kyria/rules.mk index 61d90c67c15d..2c749186af69 100644 --- a/keyboards/kyria/rules.mk +++ b/keyboards/kyria/rules.mk @@ -2,13 +2,6 @@ MCU = atmega32u4 # Bootloader selection -# Teensy halfkay -# Pro Micro caterina -# Atmel DFU atmel-dfu -# LUFA DFU lufa-dfu -# QMK DFU qmk-dfu -# ATmega32A bootloadHID -# ATmega328P USBasp BOOTLOADER = atmel-dfu # Build Options diff --git a/keyboards/mb44/config.h b/keyboards/mb44/config.h new file mode 100644 index 000000000000..013efa85704a --- /dev/null +++ b/keyboards/mb44/config.h @@ -0,0 +1,61 @@ +/* +Copyright 2021 melonbred + +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 "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x6d62 +#define PRODUCT_ID 0x6d62 +#define DEVICE_VER 0x0001 +#define MANUFACTURER melonbred + + +/* key matrix size */ +#define MATRIX_ROWS 4 +#define MATRIX_COLS 12 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { D1, D6, D5, D4 } +#define MATRIX_COL_PINS { C4, C5, C6, C7, B7, B6, B5, B4, B3, B2, B1, B0 } +#define UNUSED_PINS { C2 } + +/* COL2ROW, ROW2COL*/ +#define DIODE_DIRECTION COL2ROW + +/*Encoder Definition*/ +#define ENCODERS_PAD_A { D3 } +#define ENCODERS_PAD_B { D2 } + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + + +/* disable these deprecated features by default */ +#define NO_ACTION_MACRO +#define NO_ACTION_FUNCTION + diff --git a/keyboards/mb44/info.json b/keyboards/mb44/info.json new file mode 100644 index 000000000000..d18a0b0142a9 --- /dev/null +++ b/keyboards/mb44/info.json @@ -0,0 +1,202 @@ +{ + "keyboard_name": "MB-44", + "url": "", + "maintainer": "melonbred", + "width": 3, + "height": 2, + "layouts": { + "LAYOUT_default": { + "layout": [ + {"x":0, "y":0}, + {"x":1, "y":0}, + {"x":2, "y":0}, + {"x":3, "y":0}, + {"x":4, "y":0}, + {"x":5, "y":0}, + {"x":6, "y":0}, + {"x":7, "y":0}, + {"x":8, "y":0}, + {"x":9, "y":0}, + {"x":10, "y":0}, + {"x":11, "y":0, "w":1.75}, + {"x":0, "y":1, "w":1.25}, + {"x":1.25, "y":1}, + {"x":2.25, "y":1}, + {"x":3.25, "y":1}, + {"x":4.25, "y":1}, + {"x":5.25, "y":1}, + {"x":6.25, "y":1}, + {"x":7.25, "y":1}, + {"x":8.25, "y":1}, + {"x":9.25, "y":1}, + {"x":10.25, "y":1}, + {"x":11.25, "y":1, "w":1.5}, + {"x":0, "y":2, "w":1.75}, + {"x":1.75, "y":2}, + {"x":2.75, "y":2}, + {"x":3.75, "y":2}, + {"x":4.75, "y":2}, + {"x":5.75, "y":2}, + {"x":6.75, "y":2}, + {"x":7.75, "y":2}, + {"x":8.75, "y":2}, + {"x":9.75, "y":2}, + {"x":10.75, "y":2}, + {"x":11.75, "y":2}, + {"x":0, "y":3}, + {"x":1, "y":3}, + {"x":2, "y":3}, + {"x":3, "y":3, "w":6.25}, + {"x":9.75, "y":3}, + {"x":10.75, "y":3}, + {"x":11.75, "y":3} + ] + }, + "LAYOUT_2u_split": { + "layout": [ + {"x":0, "y":0}, + {"x":1, "y":0}, + {"x":2, "y":0}, + {"x":3, "y":0}, + {"x":4, "y":0}, + {"x":5, "y":0}, + {"x":6, "y":0}, + {"x":7, "y":0}, + {"x":8, "y":0}, + {"x":9, "y":0}, + {"x":10, "y":0}, + {"x":11, "y":0, "w":1.75}, + {"x":0, "y":1, "w":1.25}, + {"x":1.25, "y":1}, + {"x":2.25, "y":1}, + {"x":3.25, "y":1}, + {"x":4.25, "y":1}, + {"x":5.25, "y":1}, + {"x":6.25, "y":1}, + {"x":7.25, "y":1}, + {"x":8.25, "y":1}, + {"x":9.25, "y":1}, + {"x":10.25, "y":1}, + {"x":11.25, "y":1, "w":1.5}, + {"x":0, "y":2, "w":1.75}, + {"x":1.75, "y":2}, + {"x":2.75, "y":2}, + {"x":3.75, "y":2}, + {"x":4.75, "y":2}, + {"x":5.75, "y":2}, + {"x":6.75, "y":2}, + {"x":7.75, "y":2}, + {"x":8.75, "y":2}, + {"x":9.75, "y":2}, + {"x":10.75, "y":2}, + {"x":11.75, "y":2}, + {"x":0, "y":3}, + {"x":1, "y":3, "w":1.25}, + {"x":2.25, "y":3}, + {"x":3.25, "y":3, "w":2.25}, + {"x":5.5, "y":3}, + {"x":6.5, "y":3, "w":2.75}, + {"x":9.75, "y":3}, + {"x":10.75, "y":3}, + {"x":11.75, "y":3} + ] + }, + "LAYOUT_2u1u_split": { + "layout": [ + {"x":0, "y":0}, + {"x":1, "y":0}, + {"x":2, "y":0}, + {"x":3, "y":0}, + {"x":4, "y":0}, + {"x":5, "y":0}, + {"x":6, "y":0}, + {"x":7, "y":0}, + {"x":8, "y":0}, + {"x":9, "y":0}, + {"x":10, "y":0}, + {"x":11, "y":0, "w":1.75}, + {"x":0, "y":1, "w":1.25}, + {"x":1.25, "y":1}, + {"x":2.25, "y":1}, + {"x":3.25, "y":1}, + {"x":4.25, "y":1}, + {"x":5.25, "y":1}, + {"x":6.25, "y":1}, + {"x":7.25, "y":1}, + {"x":8.25, "y":1}, + {"x":9.25, "y":1}, + {"x":10.25, "y":1}, + {"x":11.25, "y":1, "w":1.5}, + {"x":0, "y":2, "w":1.75}, + {"x":1.75, "y":2}, + {"x":2.75, "y":2}, + {"x":3.75, "y":2}, + {"x":4.75, "y":2}, + {"x":5.75, "y":2}, + {"x":6.75, "y":2}, + {"x":7.75, "y":2}, + {"x":8.75, "y":2}, + {"x":9.75, "y":2}, + {"x":10.75, "y":2}, + {"x":11.75, "y":2}, + {"x":0, "y":3}, + {"x":1, "y":3, "w":1.25}, + {"x":2.25, "y":3}, + {"x":3.25, "y":3, "w":2.75}, + {"x":6, "y":3, "w":2.25}, + {"x":8.25, "y":3}, + {"x":9.75, "y":3}, + {"x":10.75, "y":3}, + {"x":11.75, "y":3} + ] + }, + "LAYOUT_3u_split": { + "layout": [ + {"x":0, "y":0}, + {"x":1, "y":0}, + {"x":2, "y":0}, + {"x":3, "y":0}, + {"x":4, "y":0}, + {"x":5, "y":0}, + {"x":6, "y":0}, + {"x":7, "y":0}, + {"x":8, "y":0}, + {"x":9, "y":0}, + {"x":10, "y":0}, + {"x":11, "y":0, "w":1.75}, + {"x":0, "y":1, "w":1.25}, + {"x":1.25, "y":1}, + {"x":2.25, "y":1}, + {"x":3.25, "y":1}, + {"x":4.25, "y":1}, + {"x":5.25, "y":1}, + {"x":6.25, "y":1}, + {"x":7.25, "y":1}, + {"x":8.25, "y":1}, + {"x":9.25, "y":1}, + {"x":10.25, "y":1}, + {"x":11.25, "y":1, "w":1.5}, + {"x":0, "y":2, "w":1.75}, + {"x":1.75, "y":2}, + {"x":2.75, "y":2}, + {"x":3.75, "y":2}, + {"x":4.75, "y":2}, + {"x":5.75, "y":2}, + {"x":6.75, "y":2}, + {"x":7.75, "y":2}, + {"x":8.75, "y":2}, + {"x":9.75, "y":2}, + {"x":10.75, "y":2}, + {"x":11.75, "y":2}, + {"x":0, "y":3}, + {"x":1, "y":3, "w":1.25}, + {"x":2.25, "y":3}, + {"x":3.25, "y":3, "w":3}, + {"x":6.25, "y":3, "w":3}, + {"x":9.75, "y":3}, + {"x":10.75, "y":3}, + {"x":11.75, "y":3} + ] + } + } +} diff --git a/keyboards/mb44/keymaps/2u1u_space/keymap.c b/keyboards/mb44/keymaps/2u1u_space/keymap.c new file mode 100644 index 000000000000..437a90c7b377 --- /dev/null +++ b/keyboards/mb44/keymaps/2u1u_space/keymap.c @@ -0,0 +1,59 @@ +/* Copyright 2020 melonbred + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _BASE, + _LAYER1, + _LAYER2 + +}; + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_2u1u_space( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + CTL_T(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_UP, KC_SLSH, + MO(_LAYER2), KC_LGUI, KC_LALT, LT(_LAYER1, KC_SPC), KC_RALT, KC_SPC, KC_LEFT, KC_DOWN, KC_RGHT + ), + + [_LAYER1] = LAYOUT_2u1u_space( + KC_GRV, KC_QUOT, _______, KC_UP, _______, _______, _______, _______, KC_7, KC_8, KC_9, KC_DEL, + KC_CAPS, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, KC_PSLS, KC_PMNS, KC_4, KC_5, KC_6, KC_ENT, + KC_LSFT, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, KC_PAST, KC_PPLS, KC_1, KC_2, KC_3, KC_RSFT, + _______, KC_LGUI, KC_LALT, XXXXXXX, KC_RALT, KC_SPC, KC_0, KC_PDOT, XXXXXXX + ), + + [_LAYER2] = LAYOUT_2u1u_space( + KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RESET, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLD, + _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX + ), +}; + +// Rotary Encoder Functions +void encoder_update_user(uint8_t index, bool clockwise) { + if (index == 0) { /* First encoder */ + if (clockwise) { + tap_code(KC_VOLD); + } else { + tap_code(KC_VOLU); + } + } +} diff --git a/keyboards/mb44/keymaps/2u_space/keymap.c b/keyboards/mb44/keymaps/2u_space/keymap.c new file mode 100644 index 000000000000..b2f1fb64b686 --- /dev/null +++ b/keyboards/mb44/keymaps/2u_space/keymap.c @@ -0,0 +1,59 @@ +/* Copyright 2020 melonbred + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _BASE, + _LAYER1, + _LAYER2 + +}; + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_2u_space( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + CTL_T(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_UP, KC_SLSH, + MO(_LAYER2), KC_LGUI, KC_LALT, LT(_LAYER1, KC_SPC), KC_SPC, KC_RALT, KC_LEFT, KC_DOWN, KC_RGHT + ), + + [_LAYER1] = LAYOUT_2u_space( + KC_GRV, KC_QUOT, _______, KC_UP, _______, _______, _______, _______, KC_7, KC_8, KC_9, KC_DEL, + KC_CAPS, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, KC_PSLS, KC_PMNS, KC_4, KC_5, KC_6, KC_ENT, + KC_LSFT, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, KC_PAST, KC_PPLS, KC_1, KC_2, KC_3, KC_RSFT, + _______, KC_LGUI, KC_LALT, XXXXXXX, KC_SPC, KC_RALT, KC_0, KC_PDOT, XXXXXXX + ), + + [_LAYER2] = LAYOUT_2u_space( + KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RESET, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLD, + _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX + ), +}; + +// Rotary Encoder Functions +void encoder_update_user(uint8_t index, bool clockwise) { + if (index == 0) { /* First encoder */ + if (clockwise) { + tap_code(KC_VOLD); + } else { + tap_code(KC_VOLU); + } + } +} diff --git a/keyboards/mb44/keymaps/3u_space/keymap.c b/keyboards/mb44/keymaps/3u_space/keymap.c new file mode 100644 index 000000000000..bfd01c6ea25b --- /dev/null +++ b/keyboards/mb44/keymaps/3u_space/keymap.c @@ -0,0 +1,67 @@ +/* Copyright 2020 melonbred + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _BASE, + _LAYER1, + _LAYER2, + _LAYER3 + +}; + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_3u_space( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + CTL_T(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_UP, KC_SLSH, + MO(_LAYER2), KC_LGUI, KC_LALT, LT(_LAYER1, KC_SPC), LT(_LAYER3, KC_SPC), KC_LEFT, KC_DOWN, KC_RGHT + ), + + [_LAYER1] = LAYOUT_3u_space( + KC_GRV, KC_QUOT, XXXXXXX, KC_UP, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_7, KC_8, KC_9, KC_DEL, + KC_CAPS, XXXXXXX, KC_LEFT, KC_DOWN, KC_RGHT, XXXXXXX, KC_PSLS, KC_PMNS, KC_4, KC_5, KC_6, KC_ENT, + KC_LSFT, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, KC_PAST, KC_PPLS, KC_1, KC_2, KC_3, KC_RSFT, + XXXXXXX, KC_LGUI, KC_LALT, _______, XXXXXXX, KC_0, KC_PDOT, KC_PEQL + ), + + [_LAYER2] = LAYOUT_3u_space( + KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RESET, XXXXXXX, XXXXXXX, KC_RCTL, KC_RALT, KC_DEL, KC_VOLD, + XXXXXXX, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX + ), + + [_LAYER3] = LAYOUT_3u_space( + KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_UNDS, + XXXXXXX, KC_P1, KC_P2, KC_P3, KC_P4, KC_P5, KC_P6, KC_P7, KC_P8, KC_P9, KC_P0, _______, + _______, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, + _______, XXXXXXX, XXXXXXX, XXXXXXX, _______, XXXXXXX, XXXXXXX, XXXXXXX + ), +}; + +// Rotary Encoder Functions +void encoder_update_user(uint8_t index, bool clockwise) { + if (index == 0) { /* First encoder */ + if (clockwise) { + tap_code(KC_VOLD); + } else { + tap_code(KC_VOLU); + } + } +} \ No newline at end of file diff --git a/keyboards/mb44/keymaps/default/keymap.c b/keyboards/mb44/keymaps/default/keymap.c new file mode 100644 index 000000000000..1659661f3bd7 --- /dev/null +++ b/keyboards/mb44/keymaps/default/keymap.c @@ -0,0 +1,61 @@ +/* Copyright 2020 melonbred + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _BASE, + _LAYER1, + _LAYER2 + +}; + + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_default( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + CTL_T(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_UP, KC_SLSH, + MO(_LAYER2), KC_LGUI, KC_LALT, LT(_LAYER1, KC_SPC), KC_LEFT, KC_DOWN, KC_RGHT + ), + + [_LAYER1] = LAYOUT_default( + KC_GRV, KC_QUOT, _______, KC_UP, _______, _______, _______, _______, KC_7, KC_8, KC_9, KC_DEL, + KC_CAPS, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, KC_PSLS, KC_PMNS, KC_4, KC_5, KC_6, KC_ENT, + KC_LSFT, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, KC_PAST, KC_PPLS, KC_1, KC_2, KC_3, KC_RSFT, + _______, KC_LGUI, KC_LALT, _______, KC_0, KC_PDOT, XXXXXXX + ), + + [_LAYER2] = LAYOUT_default( + KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RESET, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLD, + _______, XXXXXXX, XXXXXXX, XXXXXXX, KC_DEL, KC_RALT, KC_RCTL + ), +}; + + +// Rotary Encoder Functions +void encoder_update_user(uint8_t index, bool clockwise) { + if (index == 0) { /* First encoder */ + if (clockwise) { + tap_code(KC_VOLD); + } else { + tap_code(KC_VOLU); + } + } +} diff --git a/keyboards/mb44/keymaps/via/keymap.c b/keyboards/mb44/keymaps/via/keymap.c new file mode 100644 index 000000000000..9a998ba0a20f --- /dev/null +++ b/keyboards/mb44/keymaps/via/keymap.c @@ -0,0 +1,58 @@ +/* Copyright 2020 melonbred + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _BASE, + _LAYER1, + _LAYER2, + _LAYER3 + +}; + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_default( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + CTL_T(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_UP, KC_SLSH, + MO(_LAYER2), KC_LGUI, KC_LALT, LT(_LAYER1, KC_SPC), KC_LEFT, KC_RGHT, KC_DOWN + ), + + [_LAYER1] = LAYOUT_default( + KC_GRV, KC_QUOT, _______, KC_UP, _______, _______, _______, _______, KC_7, KC_8, KC_9, KC_DEL, + KC_CAPS, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, KC_PSLS, KC_PMNS, KC_4, KC_5, KC_6, KC_ENT, + KC_LSFT, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, KC_PAST, KC_PPLS, KC_1, KC_2, KC_3, KC_RSFT, + _______, KC_LGUI, KC_LALT, _______, KC_0, KC_PDOT, XXXXXXX + ), + + [_LAYER2] = LAYOUT_default( + KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RESET, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLD, + _______, XXXXXXX, XXXXXXX, XXXXXXX, KC_DEL, KC_RALT, KC_RCTL + ), + + [_LAYER3] = LAYOUT_default( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______ + ), + +}; + diff --git a/keyboards/mb44/keymaps/via/rules.mk b/keyboards/mb44/keymaps/via/rules.mk new file mode 100644 index 000000000000..036bd6d1c3ec --- /dev/null +++ b/keyboards/mb44/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes \ No newline at end of file diff --git a/keyboards/mb44/mb44.c b/keyboards/mb44/mb44.c new file mode 100644 index 000000000000..16f68705f807 --- /dev/null +++ b/keyboards/mb44/mb44.c @@ -0,0 +1,17 @@ +/* Copyright 2021 melonbred + * + * 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 "mb44.h" \ No newline at end of file diff --git a/keyboards/mb44/mb44.h b/keyboards/mb44/mb44.h new file mode 100644 index 000000000000..a0664d8b87de --- /dev/null +++ b/keyboards/mb44/mb44.h @@ -0,0 +1,84 @@ +/* Copyright 2021 melonbred + * + * 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" + +/* This is a shortcut to help you visually see your layout. + * + * The first section contains all of the arguments representing the physical + * layout of the board and position of the keys. + * + * The second converts the arguments into a two-dimensional array which + * represents the switch matrix. + */ + +#define XXX KC_NO + + + +#define LAYOUT_default( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, \ + K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, \ + K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, \ + K30, K31, K32, K35, K39, K3A, K3B \ +) \ +{ \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B }, \ + { K30, K31, K32, XXX, XXX, K35, XXX, XXX, XXX, K39, K3A, K3B } \ +} + +#define LAYOUT_2u_space( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, \ + K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, \ + K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, \ + K30, K31, K32, K33, K36, K37, K39, K3A, K3B \ +) \ +{ \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B }, \ + { K30, K31, K32, K33, XXX, XXX, K36, K37, XXX, K39, K3A, K3B } \ +} + +#define LAYOUT_2u1u_space( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, \ + K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, \ + K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, \ + K30, K31, K32, K33, K35, K36, K39, K3A, K3B \ +) \ +{ \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B }, \ + { K30, K31, K32, K33, XXX, K35, K36, XXX, XXX, K39, K3A, K3B } \ +} + +#define LAYOUT_3u_space( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, \ + K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, \ + K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, \ + K30, K31, K32, K33, K36, K39, K3A, K3B \ +) \ +{ \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B }, \ + { K30, K31, K32, K33, XXX, XXX, K36, XXX, XXX, K39, K3A, K3B } \ +} diff --git a/keyboards/mb44/readme.md b/keyboards/mb44/readme.md new file mode 100644 index 000000000000..3cd59ecdb136 --- /dev/null +++ b/keyboards/mb44/readme.md @@ -0,0 +1,15 @@ +# MB-44 + +![MB-44](https://imgur.com/sECiIHR.jpg) + +To reset and put into bootloader mode, please use the hardware reset button on the botton of the PCB. If the PCB is on the default firmware, software reset is available by holding the bottom left corner key and pressing `B` in the standard qwerty layout. + +* Keyboard Maintainer: [melonbred](https://github.com/melonbred) +* Hardware Supported: The PCBs, controllers supported +* Hardware Availability: Links to where you can find this hardware + +Make example for this keyboard (after setting up your build environment): + + make mb44: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). diff --git a/keyboards/mb44/rules.mk b/keyboards/mb44/rules.mk new file mode 100644 index 000000000000..ba7e249c9b4f --- /dev/null +++ b/keyboards/mb44/rules.mk @@ -0,0 +1,23 @@ +# MCU name +MCU = atmega32u2 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = no # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output +ENCODER_ENABLE = yes # Enable rotary encoder diff --git a/keyboards/mechwild/murphpad/config.h b/keyboards/mechwild/murphpad/config.h index e107ad260b10..0887025ad843 100644 --- a/keyboards/mechwild/murphpad/config.h +++ b/keyboards/mechwild/murphpad/config.h @@ -36,8 +36,8 @@ along with this program. If not, see . #define UNUSED_PINS /* Encoder pins */ -#define ENCODERS_PAD_A { E6 } -#define ENCODERS_PAD_B { B4 } +#define ENCODERS_PAD_A { E6, D2 } +#define ENCODERS_PAD_B { B4, D3 } /* Encoder resolution */ #define ENCODER_RESOLUTION 4 diff --git a/keyboards/mechwild/murphpad/keymaps/default/keymap.c b/keyboards/mechwild/murphpad/keymaps/default/keymap.c index 685cc9108d16..eace87cd64b7 100644 --- a/keyboards/mechwild/murphpad/keymaps/default/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/default/keymap.c @@ -18,8 +18,8 @@ // Defines names for use in layer keycodes and the keymap enum layer_names { - _BASE, - _FN1, + _BASE, + _FN1, _FN2, _FN3 }; @@ -28,46 +28,46 @@ enum layer_names { const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { /* Base */ [_BASE] = LAYOUT( - KC_F1, KC_F2, KC_F3, KC_F4, - KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, - KC_P7, KC_P8, KC_P9, KC_PPLS, - KC_MUTE, KC_P4, KC_P5, KC_P6, KC_NO, - MO(_FN1), KC_P1, KC_P2, KC_P3, KC_PENT, - KC_BSPC, KC_P0, KC_NO, KC_PDOT, KC_NO, + KC_F1, KC_F2, KC_F3, KC_F4, + KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + KC_P7, KC_P8, KC_P9, KC_PPLS, + KC_MUTE, KC_P4, KC_P5, KC_P6, _______, + MO(_FN1), KC_P1, KC_P2, KC_P3, KC_PENT, + KC_BSPC, KC_P0, _______, KC_PDOT, _______, - KC_F5, KC_F6, KC_F7 + KC_F5, KC_F6, KC_F7 ), [_FN1] = LAYOUT( _______, _______, _______, _______, _______, _______, _______, _______, RGB_HUD, RGB_SPI, RGB_HUI, _______, - _______, RGB_RMOD, RGB_TOG, RGB_MOD, KC_NO, + _______, RGB_RMOD, RGB_TOG, RGB_MOD, _______, _______, RGB_VAD, RGB_SPD, RGB_VAI, _______, - _______, RGB_SAD, KC_NO, RGB_SAI, KC_NO, + _______, RGB_SAD, _______, RGB_SAI, _______, - _______, _______, _______ + _______, _______, _______ ), - [_FN2] = LAYOUT( - _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, KC_NO, + [_FN2] = LAYOUT( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, KC_NO, - + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______ ), - [_FN3] = LAYOUT( - _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, KC_NO, + [_FN3] = LAYOUT( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, KC_NO, - + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______ ) @@ -82,6 +82,13 @@ bool encoder_update_user(uint8_t index, bool clockwise) { } else { tap_code(KC_VOLD); } + break; + case 1: + if (clockwise) { + tap_code(KC_BRIU); + } else { + tap_code(KC_BRID); + } break; } return true; diff --git a/keyboards/mechwild/murphpad/keymaps/via/keymap.c b/keyboards/mechwild/murphpad/keymaps/via/keymap.c index bd74d2184f11..f7d381940374 100644 --- a/keyboards/mechwild/murphpad/keymaps/via/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/via/keymap.c @@ -17,8 +17,8 @@ // Defines names for use in layer keycodes and the keymap enum layer_names { - _BASE, - _FN1, + _BASE, + _FN1, _FN2, _FN3 }; @@ -26,49 +26,49 @@ enum layer_names { const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { /* Base */ [_BASE] = LAYOUT( - KC_F1, KC_F2, KC_F3, KC_F4, - KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, - KC_P7, KC_P8, KC_P9, KC_PPLS, - KC_MUTE, KC_P4, KC_P5, KC_P6, KC_NO, - MO(_FN1), KC_P1, KC_P2, KC_P3, KC_PENT, - KC_BSPC, KC_P0, KC_NO, KC_PDOT, KC_NO, - - _______, _______, _______ + KC_F1, KC_F2, KC_F3, KC_F4, + KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + KC_P7, KC_P8, KC_P9, KC_PPLS, + KC_MUTE, KC_P4, KC_P5, KC_P6, _______, + MO(_FN1), KC_P1, KC_P2, KC_P3, KC_PENT, + KC_BSPC, KC_P0, _______, KC_PDOT, _______, + + KC_F5, KC_F6, KC_F7 ), [_FN1] = LAYOUT( - _______, _______, _______, _______, - _______, _______, _______, _______, - RGB_HUD, RGB_SPI, RGB_HUI, _______, - _______, RGB_RMOD, RGB_TOG, RGB_MOD, KC_NO, - _______, RGB_VAD, RGB_SPD, RGB_VAI, _______, - _______, RGB_SAD, KC_NO, RGB_SAI, KC_NO, - - _______, _______, _______ + _______, _______, _______, _______, + _______, _______, _______, _______, + RGB_HUD, RGB_SPI, RGB_HUI, _______, + _______, RGB_RMOD, RGB_TOG, RGB_MOD, _______, + _______, RGB_VAD, RGB_SPD, RGB_VAI, _______, + _______, RGB_SAD, _______, RGB_SAI, _______, + + _______, _______, _______ ), - [_FN2] = LAYOUT( - _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, KC_NO, - _______, _______, _______, _______, _______, - _______, _______, _______, _______, KC_NO, - - _______, _______, _______ + [_FN2] = LAYOUT( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + + _______, _______, _______ ), - [_FN3] = LAYOUT( - _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, KC_NO, - _______, _______, _______, _______, _______, - _______, _______, _______, _______, KC_NO, - - _______, _______, _______ + [_FN3] = LAYOUT( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + + _______, _______, _______ - ) + ) }; #ifdef ENCODER_ENABLE @@ -80,6 +80,13 @@ bool encoder_update_user(uint8_t index, bool clockwise) { } else { tap_code(KC_VOLD); } + break; + case 1: + if (clockwise) { + tap_code(KC_BRIU); + } else { + tap_code(KC_BRID); + } break; } return true; diff --git a/keyboards/mechwild/murphpad/readme.md b/keyboards/mechwild/murphpad/readme.md index 6318aeae119a..3f46af48b9ba 100644 --- a/keyboards/mechwild/murphpad/readme.md +++ b/keyboards/mechwild/murphpad/readme.md @@ -5,7 +5,7 @@ A DIY numpad kit with macro row, two additional keys, OLED, RGB Underglow, and encoder. * Keyboard Maintainer: [Kyle McCreery](https://github.com/kylemccreery) -* Hardware Supported: MurphPad v2.0 +* Hardware Supported: MurphPad v3.1 * Hardware Availability: [MurphPad on MechWild](https://mechwild.com/product/murphpad/) Make example for this keyboard (after setting up your build environment): diff --git a/keyboards/pistachio/config.h b/keyboards/pistachio/config.h index e427f90ec1bf..461a364ec92a 100644 --- a/keyboards/pistachio/config.h +++ b/keyboards/pistachio/config.h @@ -20,7 +20,7 @@ along with this program. If not, see . #include "config_common.h" /* USB Device descriptor parameter */ -#define VENDOR_ID 0xFEED +#define VENDOR_ID 0x5255 #define PRODUCT_ID 0xD0C2 #define DEVICE_VER 0x0001 #define MANUFACTURER rate diff --git a/keyboards/pistachio/keymaps/rate/keymap.c b/keyboards/pistachio/keymaps/rate/keymap.c new file mode 100644 index 000000000000..34e1324aed99 --- /dev/null +++ b/keyboards/pistachio/keymaps/rate/keymap.c @@ -0,0 +1,69 @@ +/* Copyright 2020 rate + * + * 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_jp.h" + + +enum layer_names { + _QWERTY = 0, + _FN, + _NUM +}; + +enum custom_keycodes { + RGB_RST = SAFE_RANGE +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_QWERTY] = LAYOUT( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_DEL, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, + KC_0, KC_ZKHK, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, JP_MINS, JP_CIRC, JP_YEN, KC_BSPC, KC_DEL, + KC_H, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, JP_AT, JP_LBRC, KC_HOME, + KC_U, KC_ENT, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, JP_SCLN, JP_COLN, JP_RBRC, KC_ENT, KC_END, + KC_VOLU, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, JP_COMM, JP_DOT, JP_SLSH, JP_BSLS, KC_RSFT, KC_PGUP, + KC_VOLD, KC_LCTRL, KC_LGUI, KC_LALT, KC_LALT, LT(_NUM, KC_M), KC_SPC, LT(_FN, KC_SPC), KC_MPLY, JP_KANA, KC_UP, KC_DOWN, KC_INS, KC_RCTRL, KC_PGDN + ), + [_FN] = LAYOUT( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_VAD, _______, _______, _______, _______, KC_UP, _______, _______, KC_HOME, KC_END, _______, KC_PGUP, _______, _______, _______, + _______, _______, _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______, KC_LEFT, KC_UP, KC_DOWN, KC_RIGHT, KC_PGDN, _______, _______, _______, _______, + RGB_HUI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_SAI, + RGB_HUD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_SAD + ), + [_NUM] = LAYOUT( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_PMNS, _______, _______, _______, _______, + RGB_VAD, KC_7, KC_8, KC_9, _______, _______, _______, KC_7, KC_8, KC_9, _______, _______, _______, _______, _______, + _______, KC_4, KC_5, KC_6, _______, _______, _______, KC_4, KC_5, KC_6, _______, KC_PPLS, KC_PAST, _______, _______, _______, + RGB_HUI, KC_1, KC_2, KC_3, KC_0, JP_DOT, _______, KC_1, KC_2, KC_3, _______, KC_PSLS, _______, _______, RGB_SAI, + RGB_HUD, _______, _______, _______, _______, _______, _______, KC_0, _______, JP_DOT, _______, _______, _______, _______, RGB_SAD + ) +}; + + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case RGB_RST: + if (record->event.pressed) { + eeconfig_update_rgblight_default(); + rgblight_enable(); + } + break; + } + + return true; +} diff --git a/keyboards/pistachio/keymaps/via/keymap.c b/keyboards/pistachio/keymaps/via/keymap.c new file mode 100644 index 000000000000..357253ac2dbd --- /dev/null +++ b/keyboards/pistachio/keymaps/via/keymap.c @@ -0,0 +1,78 @@ +/* Copyright 2020 rate + * + * 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_jp.h" + + +enum layer_names { + _QWERTY = 0, + _FN, + _NUM, + _RESERVE +}; + +enum custom_keycodes { + RGB_RST = SAFE_RANGE +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_QWERTY] = LAYOUT( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_DEL, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, + KC_0, KC_ZKHK, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, JP_MINS, JP_CIRC, JP_YEN, KC_BSPC, KC_DEL, + KC_H, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, JP_AT, JP_LBRC, KC_HOME, + KC_U, KC_ENT, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, JP_SCLN, JP_COLN, JP_RBRC, KC_ENT, KC_END, + KC_VOLU, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, JP_COMM, JP_DOT, JP_SLSH, JP_BSLS, KC_RSFT, KC_PGUP, + KC_VOLD, KC_LCTRL, KC_LGUI, KC_LALT, KC_LALT, LT(_NUM, KC_M), KC_SPC, LT(_FN, KC_SPC), KC_MPLY, JP_KANA, KC_UP, KC_DOWN, KC_INS, KC_RCTRL, KC_PGDN + ), + [_FN] = LAYOUT( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_VAD, _______, _______, _______, _______, KC_UP, _______, _______, KC_HOME, KC_END, _______, KC_PGUP, _______, _______, _______, + _______, _______, _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______, KC_LEFT, KC_UP, KC_DOWN, KC_RIGHT, KC_PGDN, _______, _______, _______, _______, + RGB_HUI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_SAI, + RGB_HUD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_SAD + ), + [_NUM] = LAYOUT( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_VAI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_PMNS, _______, _______, _______, _______, + RGB_VAD, KC_7, KC_8, KC_9, _______, _______, _______, KC_7, KC_8, KC_9, _______, _______, _______, _______, _______, + _______, KC_4, KC_5, KC_6, _______, _______, _______, KC_4, KC_5, KC_6, _______, KC_PPLS, KC_PAST, _______, _______, _______, + RGB_HUI, KC_1, KC_2, KC_3, KC_0, JP_DOT, _______, KC_1, KC_2, KC_3, _______, KC_PSLS, _______, _______, RGB_SAI, + RGB_HUD, _______, _______, _______, _______, _______, _______, KC_0, _______, JP_DOT, _______, _______, _______, _______, RGB_SAD + ), + [_RESERVE] = LAYOUT( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ) +}; + + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case RGB_RST: + if (record->event.pressed) { + eeconfig_update_rgblight_default(); + rgblight_enable(); + } + break; + } + + return true; +} diff --git a/keyboards/pistachio/keymaps/via/rules.mk b/keyboards/pistachio/keymaps/via/rules.mk new file mode 100644 index 000000000000..036bd6d1c3ec --- /dev/null +++ b/keyboards/pistachio/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes \ No newline at end of file diff --git a/keyboards/planck/keymaps/mnil/config.h b/keyboards/planck/keymaps/mnil/config.h new file mode 100644 index 000000000000..2dc8e19be651 --- /dev/null +++ b/keyboards/planck/keymaps/mnil/config.h @@ -0,0 +1,23 @@ +/* Copyright 2021 Mats Nilsson + * + * 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 + +#ifdef AUDIO_ENABLE +# define STARTUP_SONG SONG(NO_SOUND) +#endif + +#define MIDI_BASIC diff --git a/keyboards/planck/keymaps/mnil/keymap.c b/keyboards/planck/keymaps/mnil/keymap.c new file mode 100644 index 000000000000..85d84d2c65fe --- /dev/null +++ b/keyboards/planck/keymaps/mnil/keymap.c @@ -0,0 +1,60 @@ +/* Copyright 2021 Mats Nilsson + * + * 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 "mnil.h" + +layer_state_t layer_state_set_user(layer_state_t state) { return update_tri_layer_state(state, _SYMBOLS, _NAVIGATION, _NUMPAD); } + +// clang-format off +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + +[_COLEMAK] = LAYOUT_planck_2x2u( + KC_ESC, KC_Q, KC_W, KC_F, KC_P, KC_B, KC_J, KC_L, KC_U, KC_Y, TD(OAA), KC_BSPC, + KC_TAB, TD(AAE), KC_R, KC_S, KC_T, KC_G, KC_M, KC_N, KC_E, KC_I, KC_O, KC_NO, + KC_LSFT, KC_Z, KC_X, KC_C, KC_D, KC_V, KC_K, KC_H, KC_COMM, KC_DOT, SE_MINS, KC_NO , + KC_LCTL, KC_NO, KC_LGUI, SFT_TAB, _NAV_SPC, _SYM_ENT, CTL_BSPC,ALT_DEL, KC_NO, KC_LGUI +), + +[_QWERTY] = LAYOUT_planck_2x2u( + KC_TRNS, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, SE_AA, + KC_TRNS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, SE_OSLH, SE_AE, + KC_TRNS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS +), + +[_SYMBOLS] = LAYOUT_planck_2x2u( + KC_TRNS, KC_NO, SE_PIPE, SE_LBRC, SE_RBRC, KC_NO, S(KC_5), SE_QUES, SE_AT, SE_EQL, SE_DLR, KC_BSPC, + KC_TRNS, SE_LCBR, SE_RCBR, SE_LPRN, SE_RPRN, KC_NO, SE_PLUS, S(KC_1), S(KC_2), S(KC_3), SE_AMPR, KC_QUOT, + KC_TRNS, M_TILD, M_CIRC, SE_LESS, SE_GRTR, KC_NO, SE_APOS, SE_SLSH, SE_BSLS, SE_ASTR, M_BTCK, KC_ENT, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS +), + +[_NAVIGATION] = LAYOUT_planck_2x2u( + KC_TRNS, KC_NO, CUT, COPY, PASTE, AUTOFILL,KC_NO, KC_HOME, KC_WH_D, KC_WH_U, KC_END, KC_NO, + KC_TRNS, KC_ACL0, KC_ACL1, KC_BTN2, KC_BTN1, KC_LCTL, KC_WH_L, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R, KC_WH_R, + KC_TRNS, KC_ACL2, KC_BTN4, KC_BTN3, KC_BTN5, KC_NO, KC_NO, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_LCTL, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS +), + +[_NUMPAD] = LAYOUT_planck_2x2u( + KC_TRNS, QUIT, WIN, MVWSL, MVWSR, CRYWS, TERM, KC_7, KC_8, KC_9, KC_COMM, RESET, + KC_TRNS, CS_TAB, C_TAB, PRVWS, NXTWS, I3MOD, OPEN, KC_4, KC_5, KC_6, KC_0, KC_NO, + KC_TRNS, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, MOVWS, BROWSER, KC_1, KC_2, KC_3, KC_DOT, KC_NO, + QWE_COL, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS +), + +}; +// clang-format on diff --git a/keyboards/planck/keymaps/mnil/readme.md b/keyboards/planck/keymaps/mnil/readme.md new file mode 100644 index 000000000000..43c9409614b5 --- /dev/null +++ b/keyboards/planck/keymaps/mnil/readme.md @@ -0,0 +1,2 @@ +# mnil's planck keymap +Read my user settings [here](../../../../users/mnil/readme.md) for more details. diff --git a/keyboards/ploopyco/trackball_nano/keymaps/default/readme.md b/keyboards/ploopyco/trackball_nano/keymaps/default/readme.md index ebb90d2999fa..72401991c9a8 100644 --- a/keyboards/ploopyco/trackball_nano/keymaps/default/readme.md +++ b/keyboards/ploopyco/trackball_nano/keymaps/default/readme.md @@ -1,3 +1 @@ -The default keymap for the Ploopy Trackball Mini. - -Note that kits bought from PloopyCo actually ship with the VIA keymap, not this one. \ No newline at end of file +The default keymap for the Ploopy Trackball Nano. diff --git a/keyboards/switchplate/switchplate910/config.h b/keyboards/switchplate/switchplate910/config.h new file mode 100644 index 000000000000..81f825470301 --- /dev/null +++ b/keyboards/switchplate/switchplate910/config.h @@ -0,0 +1,87 @@ +/* +Copyright 2021 Stefan Karsch + +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 "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x54F3 +#define PRODUCT_ID 0x2065 +#define DEVICE_VER 0x0001 +#define MANUFACTURER Switchplate Peripherals +#define PRODUCT 910 + +/* key matrix size */ +#define MATRIX_ROWS 5 +#define MATRIX_COLS 15 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { F4, F5, F6, F7, D1 } +#define MATRIX_COL_PINS { D2, D3, D5, D4, D6, D7, B4, B5, B6, C6, C7, B3, B2, B0, B1 } +#define UNUSED_PINS + +/* COL2ROW, ROW2COL*/ +#define DIODE_DIRECTION COL2ROW + +#define BACKLIGHT_PIN B7 +// #define BACKLIGHT_BREATHING +#define BACKLIGHT_LEVELS 3 + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* define if matrix has ghost (lacks anti-ghosting diodes) */ +//#define MATRIX_HAS_GHOST + +/* 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 + +/* + * Feature disable options + * These options are also useful to firmware size reduction. + */ + +/* disable debug print */ +//#define NO_DEBUG + +/* disable print */ +//#define NO_PRINT + +/* disable action features */ +//#define NO_ACTION_LAYER +//#define NO_ACTION_TAPPING +//#define NO_ACTION_ONESHOT + +/* disable these deprecated features by default */ +#define NO_ACTION_MACRO +#define NO_ACTION_FUNCTION + +/* Bootmagic Lite key configuration */ +// #define BOOTMAGIC_LITE_ROW 0 +// #define BOOTMAGIC_LITE_COLUMN 0 diff --git a/keyboards/switchplate/switchplate910/info.json b/keyboards/switchplate/switchplate910/info.json new file mode 100644 index 000000000000..bbdcd3da0004 --- /dev/null +++ b/keyboards/switchplate/switchplate910/info.json @@ -0,0 +1,297 @@ +{ + "keyboard_name": "southpaw910", + "url": "", + "maintainer": "MxBluE", + "width": 22.5, + "height": 6.25, + "layouts": { + "LAYOUT_all": { + "layout": [ + { + "x": 0, + "y": 0 + }, + { + "x": 1, + "y": 0 + }, + { + "x": 2, + "y": 0 + }, + { + "x": 3, + "y": 0 + }, + { + "x": 4, + "y": 0 + }, + { + "x": 5, + "y": 0 + }, + { + "x": 6, + "y": 0 + }, + { + "x": 7, + "y": 0 + }, + { + "x": 8, + "y": 0 + }, + { + "x": 9, + "y": 0 + }, + { + "x": 10, + "y": 0 + }, + { + "x": 11, + "y": 0 + }, + { + "x": 12, + "y": 0 + }, + { + "x": 13, + "y": 0 + }, + { + "x": 14, + "y": 0 + }, + { + "x": 15, + "y": 0 + }, + { + "x": 0, + "y": 1, + "w": 1.5 + }, + { + "x": 1.5, + "y": 1 + }, + { + "x": 2.5, + "y": 1 + }, + { + "x": 3.5, + "y": 1 + }, + { + "x": 4.5, + "y": 1 + }, + { + "x": 5.5, + "y": 1 + }, + { + "x": 6.5, + "y": 1 + }, + { + "x": 7.5, + "y": 1 + }, + { + "x": 8.5, + "y": 1 + }, + { + "x": 9.5, + "y": 1 + }, + { + "x": 10.5, + "y": 1 + }, + { + "x": 11.5, + "y": 1 + }, + { + "x": 12.5, + "y": 1 + }, + { + "x": 13.5, + "y": 1, + "w": 1.5 + }, + { + "x": 15, + "y": 1 + }, + { + "x": 0, + "y": 2, + "w": 1.75 + }, + { + "x": 1.75, + "y": 2 + }, + { + "x": 2.75, + "y": 2 + }, + { + "x": 3.75, + "y": 2 + }, + { + "x": 4.75, + "y": 2 + }, + { + "x": 5.75, + "y": 2 + }, + { + "x": 6.75, + "y": 2 + }, + { + "x": 7.75, + "y": 2 + }, + { + "x": 8.75, + "y": 2 + }, + { + "x": 9.75, + "y": 2 + }, + { + "x": 10.75, + "y": 2 + }, + { + "x": 11.75, + "y": 2 + }, + { + "x": 12.75, + "y": 2, + "w": 2.25 + }, + { + "x": 15, + "y": 2 + }, + { + "x": 0, + "y": 3, + "w": 2.25 + }, + { + "x": 2.25, + "y": 3 + }, + { + "x": 3.25, + "y": 3 + }, + { + "x": 4.25, + "y": 3 + }, + { + "x": 5.25, + "y": 3 + }, + { + "x": 6.25, + "y": 3 + }, + { + "x": 7.25, + "y": 3 + }, + { + "x": 8.25, + "y": 3 + }, + { + "x": 9.25, + "y": 3 + }, + { + "x": 10.25, + "y": 3 + }, + { + "x": 11.25, + "y": 3 + }, + { + "x": 12.25, + "y": 3, + "w": 1.75 + }, + { + "x": 14, + "y": 3 + }, + { + "x": 15, + "y": 3 + }, + { + "x": 0, + "y": 4, + "w": 1.25 + }, + { + "x": 1.25, + "y": 4, + "w": 1.25 + }, + { + "x": 2.5, + "y": 4, + "w": 1.25 + }, + { + "x": 3.75, + "y": 4, + "w": 6.25 + }, + { + "x": 10, + "y": 4, + "w": 1.25 + }, + { + "x": 11.25, + "y": 4, + "w": 1.25 + }, + { + "x": 13, + "y": 4 + }, + { + "x": 14, + "y": 4 + }, + { + "x": 15, + "y": 4 + } + ] + } + } +} diff --git a/keyboards/switchplate/switchplate910/keymaps/default/keymap.c b/keyboards/switchplate/switchplate910/keymaps/default/keymap.c new file mode 100644 index 000000000000..5277a0dc0078 --- /dev/null +++ b/keyboards/switchplate/switchplate910/keymaps/default/keymap.c @@ -0,0 +1,40 @@ +/* Copyright 2021 Stefan Karsch + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _BASE, + _FN +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + LAYOUT_all( /* Base */ + KC_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_TRNS, + 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_CAPSLOCK, 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_SPACE, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT +), + + LAYOUT_all( /* L1 */ + 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_INS, KC_TRNS, + KC_TRNS, KC_MPLY, KC_MPRV, KC_MNXT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_PSCR, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAI, + RESET, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_END, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAD, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_MUTE, KC_VOLD, KC_VOLU, KC_TRNS, RGB_MOD, RGB_SAI, RGB_TOG, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_HUD, RGB_SAD, RGB_HUI +), +}; diff --git a/keyboards/switchplate/switchplate910/keymaps/default/readme.md b/keyboards/switchplate/switchplate910/keymaps/default/readme.md new file mode 100644 index 000000000000..19ca528e96e6 --- /dev/null +++ b/keyboards/switchplate/switchplate910/keymaps/default/readme.md @@ -0,0 +1,3 @@ +# The default keymap for Switchplate910 + +Nothing special \ No newline at end of file diff --git a/keyboards/switchplate/switchplate910/keymaps/via/keymap.c b/keyboards/switchplate/switchplate910/keymaps/via/keymap.c new file mode 100644 index 000000000000..c278772543cf --- /dev/null +++ b/keyboards/switchplate/switchplate910/keymaps/via/keymap.c @@ -0,0 +1,57 @@ +/* Copyright 2021 Stefan Karsch + * + * 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 + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _BASE, + _FN +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + LAYOUT_all( /* Base */ + KC_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_TRNS, + 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_CAPSLOCK, 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_SPACE, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT +), + + LAYOUT_all( /* L1 */ + 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_INS, KC_TRNS, + KC_TRNS, KC_MPLY, KC_MPRV, KC_MNXT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_PSCR, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAI, + RESET, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_END, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAD, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_MUTE, KC_VOLD, KC_VOLU, KC_TRNS, RGB_MOD, RGB_SAI, RGB_TOG, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_HUD, RGB_SAD, RGB_HUI +), + + LAYOUT_all( /* L2 */ + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, 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_all( /* L3 */ + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, 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/switchplate/switchplate910/keymaps/via/rules.mk b/keyboards/switchplate/switchplate910/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/switchplate/switchplate910/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/switchplate/switchplate910/readme.md b/keyboards/switchplate/switchplate910/readme.md new file mode 100644 index 000000000000..199a8c117bfe --- /dev/null +++ b/keyboards/switchplate/switchplate910/readme.md @@ -0,0 +1,13 @@ +# Switchplate910 + +Acoustic cut PCB for the TGR 910 + +* Keyboard Maintainer: [Switchplate Peripherals](https://switchplate.co/)/[ai03](https://github.com/ai03-2725) +* Hardware Supported: Switchplate910 PCB +* Hardware Availability: GB + +Make example for this keyboard (after setting up your build environment): + + make switchplate/switchplate910: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). diff --git a/keyboards/switchplate/switchplate910/rules.mk b/keyboards/switchplate/switchplate910/rules.mk new file mode 100644 index 000000000000..6e53d4cab232 --- /dev/null +++ b/keyboards/switchplate/switchplate910/rules.mk @@ -0,0 +1,22 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = no # USB Nkey Rollover +BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output diff --git a/keyboards/switchplate/switchplate910/switchplate910.c b/keyboards/switchplate/switchplate910/switchplate910.c new file mode 100644 index 000000000000..fce0d307233f --- /dev/null +++ b/keyboards/switchplate/switchplate910/switchplate910.c @@ -0,0 +1,18 @@ +/* Copyright 2021 Stefan Karsch + * + * 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 "switchplate910.h" + diff --git a/keyboards/switchplate/switchplate910/switchplate910.h b/keyboards/switchplate/switchplate910/switchplate910.h new file mode 100644 index 000000000000..7142ec779321 --- /dev/null +++ b/keyboards/switchplate/switchplate910/switchplate910.h @@ -0,0 +1,43 @@ +/* Copyright 2021 Stefan Karsch + * + * 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" + +/* This is a shortcut to help you visually see your layout. + * + * The first section contains all of the arguments representing the physical + * layout of the board and position of the keys. + * + * The second converts the arguments into a two-dimensional array which + * represents the switch matrix. + */ + +#define LAYOUT_all( \ + K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014, K213, \ + K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114, \ + K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K214, \ + K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K312, K314, \ + K400, K401, K402, K405, K408, K409, K411, K412, K414 \ +) \ +{ \ + { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014 }, \ + { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114 }, \ + { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K213, K214 }, \ + { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K312, KC_NO, K314 }, \ + { K400, K401, K402, KC_NO, KC_NO, K405, KC_NO, KC_NO, K408, K409, KC_NO, K411, K412, KC_NO, K414 } \ +} diff --git a/keyboards/tada68/rules.mk b/keyboards/tada68/rules.mk index a7c3cf1e3579..47fdba5554d9 100755 --- a/keyboards/tada68/rules.mk +++ b/keyboards/tada68/rules.mk @@ -11,6 +11,9 @@ MCU = atmega32u4 # ATmega328P USBasp BOOTLOADER = lufa-ms +# This board uses the older unsafe 6k version of lufa-ms +BOOTLOADER_SIZE = 6144 + # Build Options # change yes to no to disable # diff --git a/keyboards/tender/macrowo_pad/config.h b/keyboards/tender/macrowo_pad/config.h new file mode 100644 index 000000000000..51f8fbb149d6 --- /dev/null +++ b/keyboards/tender/macrowo_pad/config.h @@ -0,0 +1,40 @@ +/* Copyright 2021 swiftrax + * + * 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 "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x04D8 +#define PRODUCT_ID 0xE936 +#define DEVICE_VER 0x0001 +#define MANUFACTURER Tender +#define PRODUCT Macrowo Pad +/* key matrix size */ +#define MATRIX_ROWS 2 +#define MATRIX_COLS 10 + +/* key matrix pins */ +#define MATRIX_ROW_PINS { B5, D7 } +#define MATRIX_COL_PINS { E6, B4, B6, B2, B3, B1, F7, F6, F5, F4 } +#define UNUSED_PINS + +/* COL2ROW or ROW2COL */ +#define DIODE_DIRECTION COL2ROW + +/* Set 0 if debouncing isn't needed */ +#define DEBOUNCE 5 + diff --git a/keyboards/tender/macrowo_pad/info.json b/keyboards/tender/macrowo_pad/info.json new file mode 100644 index 000000000000..fcfc2931e9c8 --- /dev/null +++ b/keyboards/tender/macrowo_pad/info.json @@ -0,0 +1,12 @@ +{ + "keyboard_name": "Macrowo_Pad", + "url": "https//www.github.com/swiftrax", + "maintainer": "swiftrax", + "width": 11.5, + "height": 3, + "layouts": { + "LAYOUT": { + "layout": [{"label":"0,1", "x":1, "y":0}, {"label":"0,3", "x":3.25, "y":0}, {"label":"0,6", "x":7.25, "y":0}, {"label":"0,8", "x":9.5, "y":0}, {"label":"0,0", "x":0, "y":0.5}, {"label":"0,2", "x":2, "y":0.5}, {"label":"0,7", "x":8.5, "y":0.5}, {"label":"0,9", "x":10.5, "y":0.5}, {"label":"0,4", "x":3.75, "y":1}, {"label":"0,5", "x":6.75, "y":1}, {"label":"1,4", "x":5.25, "y":1.25}, {"label":"1,0", "x":0, "y":1.5}, {"label":"1,2", "x":2, "y":1.5}, {"label":"1,7", "x":8.5, "y":1.5}, {"label":"1,9", "x":10.5, "y":1.5}, {"label":"1,1", "x":1, "y":2}, {"label":"1,3", "x":4.25, "y":2}, {"label":"1,5", "x":6.25, "y":2}, {"label":"1,8", "x":9.5, "y":2}] + } + } +} \ No newline at end of file diff --git a/keyboards/tender/macrowo_pad/keymaps/default/keymap.c b/keyboards/tender/macrowo_pad/keymaps/default/keymap.c new file mode 100644 index 000000000000..f3ee17995312 --- /dev/null +++ b/keyboards/tender/macrowo_pad/keymaps/default/keymap.c @@ -0,0 +1,56 @@ +/* Copyright 2021 swiftrax + * + * 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 custom_keycodes { + SAY_OWO = SAFE_RANGE, +}; + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case SAY_OWO: + if (record->event.pressed) { + // when keycode SAY_OWO is pressed + SEND_STRING("OWO"); + } else { + // when keycode SAY_OWO is released + } + break; + } + return true; +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT( + SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, + SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO), + + [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) +}; + +#ifdef OLED_DRIVER_ENABLE +oled_rotation_t oled_init_user(oled_rotation_t rotation) { + return OLED_ROTATION_270; +} + +void oled_task_user(void) { + oled_write_P(PSTR("OWO\nWhat's\nthis?"), false); +} +#endif diff --git a/keyboards/tender/macrowo_pad/keymaps/default/rules.mk b/keyboards/tender/macrowo_pad/keymaps/default/rules.mk new file mode 100644 index 000000000000..b898ed17970f --- /dev/null +++ b/keyboards/tender/macrowo_pad/keymaps/default/rules.mk @@ -0,0 +1 @@ +OLED_DRIVER_ENABLE = yes # Enable Support for SSD1306 or SH1106 OLED Displays; Communicating over I2C \ No newline at end of file diff --git a/keyboards/tender/macrowo_pad/keymaps/via/keymap.c b/keyboards/tender/macrowo_pad/keymaps/via/keymap.c new file mode 100644 index 000000000000..9f527fd9e27e --- /dev/null +++ b/keyboards/tender/macrowo_pad/keymaps/via/keymap.c @@ -0,0 +1,64 @@ +/* Copyright 2021 swiftrax + * + * 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 custom_keycodes { + SAY_OWO = SAFE_RANGE, +}; + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case SAY_OWO: + if (record->event.pressed) { + // when keycode SAY_OWO is pressed + SEND_STRING("OWO"); + } else { + // when keycode SAY_OWO is released + } + break; + } + return true; +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT( + SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, + SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO, SAY_OWO), + + [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), + + [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), + + [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) +}; + +#ifdef OLED_DRIVER_ENABLE +oled_rotation_t oled_init_user(oled_rotation_t rotation) { + return OLED_ROTATION_270; +} + +void oled_task_user(void) { + oled_write_P(PSTR("OWO\nWhat's\nthis?"), false); +} +#endif diff --git a/keyboards/tender/macrowo_pad/keymaps/via/rules.mk b/keyboards/tender/macrowo_pad/keymaps/via/rules.mk new file mode 100644 index 000000000000..0d102b41e2f9 --- /dev/null +++ b/keyboards/tender/macrowo_pad/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +VIA_ENABLE = yes +OLED_DRIVER_ENABLE = yes # Enable Support for SSD1306 or SH1106 OLED Displays; Communicating over I2C diff --git a/keyboards/tender/macrowo_pad/macrowo_pad.c b/keyboards/tender/macrowo_pad/macrowo_pad.c new file mode 100644 index 000000000000..4dd6441e5830 --- /dev/null +++ b/keyboards/tender/macrowo_pad/macrowo_pad.c @@ -0,0 +1,17 @@ +/* Copyright 2021 swiftrax + * + * 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 "macrowo_pad.h" + \ No newline at end of file diff --git a/keyboards/tender/macrowo_pad/macrowo_pad.h b/keyboards/tender/macrowo_pad/macrowo_pad.h new file mode 100644 index 000000000000..b095c037a77c --- /dev/null +++ b/keyboards/tender/macrowo_pad/macrowo_pad.h @@ -0,0 +1,27 @@ +/* Copyright 2021 swiftrax + * + * 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, K01, K02, K03, K04, K05, K06, K07, K08, K09, \ + K10, K11, K12, K13, K14, K15, K17, K18, K19 \ +) \ +{ \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09 }, \ + { K10, K11, K12, K13, K14, K15, KC_NO, K17, K18, K19 } \ +} diff --git a/keyboards/tender/macrowo_pad/readme.md b/keyboards/tender/macrowo_pad/readme.md new file mode 100644 index 000000000000..336a06708eaa --- /dev/null +++ b/keyboards/tender/macrowo_pad/readme.md @@ -0,0 +1,16 @@ + +# Macrowo_Pad + +! Macrowo Pad + +Need I say more? + +- Keyboard Maintainer: [swiftrax](https://github.com/swiftrax) +- Hardware Supported: Macrowo_Pad, Pro Micro, Elite-C, Proton C, BlueMicro. +- Hardware Availability: Macrowo_Pad + +Make example for this keyboard (after setting up your build environment): + + make tender/macrowo_pad: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). diff --git a/keyboards/tender/macrowo_pad/rules.mk b/keyboards/tender/macrowo_pad/rules.mk new file mode 100644 index 000000000000..9d5d7c8ce981 --- /dev/null +++ b/keyboards/tender/macrowo_pad/rules.mk @@ -0,0 +1,23 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = caterina + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = no # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +MIDI_ENABLE = no # MIDI support +UNICODE_ENABLE = no # Unicode +BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID +AUDIO_ENABLE = no # Audio output on port C6 +ENCODER_ENABLE = no # Enable support for EC11 Rotary Encoder diff --git a/keyboards/thevankeyboards/minivan/rules.mk b/keyboards/thevankeyboards/minivan/rules.mk index 4e132081504a..82a739c6931d 100644 --- a/keyboards/thevankeyboards/minivan/rules.mk +++ b/keyboards/thevankeyboards/minivan/rules.mk @@ -28,3 +28,4 @@ MIDI_ENABLE = no # MIDI controls UNICODE_ENABLE = no # Unicode BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID AUDIO_ENABLE = no # Audio output on port C6 +RGBLIGHT_ENABLE = yes # Enable support for RGB LEDs diff --git a/keyboards/ztboards/noon/noon.h b/keyboards/ztboards/noon/noon.h index a38ad1f0cb5e..b5603ad1593c 100644 --- a/keyboards/ztboards/noon/noon.h +++ b/keyboards/ztboards/noon/noon.h @@ -13,5 +13,5 @@ { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, KC_NO, K115 }, \ { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, KC_NO, KC_NO, K215 }, \ { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, KC_NO, K313, KC_NO, K315 }, \ - { K400, K402, KC_NO, KC_NO, K405, KC_NO, KC_NO, KC_NO, KC_NO, K410, K411, KC_NO, K413, KC_NO, K415 } \ + { K400, KC_NO, K402, KC_NO, KC_NO, K405, KC_NO, KC_NO, KC_NO, KC_NO, K410, K411, KC_NO, K413, KC_NO, K415 } \ } diff --git a/lib/python/qmk/cli/__init__.py b/lib/python/qmk/cli/__init__.py index 48812ae4bad5..32da1a9b52e6 100644 --- a/lib/python/qmk/cli/__init__.py +++ b/lib/python/qmk/cli/__init__.py @@ -26,6 +26,42 @@ 'setup', ] +subcommands = [ + 'qmk.cli.bux', + 'qmk.cli.c2json', + 'qmk.cli.cformat', + 'qmk.cli.chibios.confmigrate', + 'qmk.cli.clean', + 'qmk.cli.compile', + 'qmk.cli.console', + 'qmk.cli.docs', + 'qmk.cli.doctor', + 'qmk.cli.fileformat', + 'qmk.cli.flash', + 'qmk.cli.format.json', + 'qmk.cli.generate.api', + 'qmk.cli.generate.config_h', + 'qmk.cli.generate.dfu_header', + 'qmk.cli.generate.docs', + 'qmk.cli.generate.info_json', + 'qmk.cli.generate.keyboard_h', + 'qmk.cli.generate.layouts', + 'qmk.cli.generate.rgb_breathe_table', + 'qmk.cli.generate.rules_mk', + 'qmk.cli.hello', + 'qmk.cli.info', + 'qmk.cli.json2c', + 'qmk.cli.lint', + 'qmk.cli.list.keyboards', + 'qmk.cli.list.keymaps', + 'qmk.cli.kle2json', + 'qmk.cli.multibuild', + 'qmk.cli.new.keyboard', + 'qmk.cli.new.keymap', + 'qmk.cli.pyformat', + 'qmk.cli.pytest', +] + def _run_cmd(*command): """Run a command in a subshell. @@ -113,7 +149,7 @@ def _broken_module_imports(requirements): milc_version = __VERSION__.split('.') -if int(milc_version[0]) < 2 and int(milc_version[1]) < 3: +if int(milc_version[0]) < 2 and int(milc_version[1]) < 4: requirements = Path('requirements.txt').resolve() print(f'Your MILC library is too old! Please upgrade: python3 -m pip install -U -r {str(requirements)}') @@ -125,7 +161,9 @@ def _broken_module_imports(requirements): while args and args[0][0] == '-': del args[0] -if not args or args[0] not in safe_commands: +safe_command = args and args[0] in safe_commands + +if not safe_command: if _broken_module_imports('requirements.txt'): if yesno('Would you like to install the required Python modules?'): _run_cmd(sys.executable, '-m', 'pip', 'install', '-r', 'requirements.txt') @@ -148,27 +186,12 @@ def _broken_module_imports(requirements): exit(1) # Import our subcommands -from . import bux # noqa -from . import c2json # noqa -from . import cformat # noqa -from . import chibios # noqa -from . import clean # noqa -from . import compile # noqa -from milc.subcommand import config # noqa -from . import console # noqa -from . import docs # noqa -from . import doctor # noqa -from . import fileformat # noqa -from . import flash # noqa -from . import format # noqa -from . import generate # noqa -from . import hello # noqa -from . import info # noqa -from . import json2c # noqa -from . import lint # noqa -from . import list # noqa -from . import kle2json # noqa -from . import multibuild # noqa -from . import new # noqa -from . import pyformat # noqa -from . import pytest # noqa +for subcommand in subcommands: + try: + __import__(subcommand) + + except ModuleNotFoundError as e: + if safe_command: + print(f'Warning: Could not import {subcommand}: {e.__class__.__name__}, {e}') + else: + raise diff --git a/lib/python/qmk/cli/chibios/__init__.py b/lib/python/qmk/cli/chibios/__init__.py index 4301837defda..e69de29bb2d1 100644 --- a/lib/python/qmk/cli/chibios/__init__.py +++ b/lib/python/qmk/cli/chibios/__init__.py @@ -1 +0,0 @@ -from . import confmigrate diff --git a/lib/python/qmk/cli/format/__init__.py b/lib/python/qmk/cli/format/__init__.py index 741ec778b116..e69de29bb2d1 100644 --- a/lib/python/qmk/cli/format/__init__.py +++ b/lib/python/qmk/cli/format/__init__.py @@ -1 +0,0 @@ -from . import json diff --git a/lib/python/qmk/cli/generate/__init__.py b/lib/python/qmk/cli/generate/__init__.py index 0efca0022dff..e69de29bb2d1 100644 --- a/lib/python/qmk/cli/generate/__init__.py +++ b/lib/python/qmk/cli/generate/__init__.py @@ -1,9 +0,0 @@ -from . import api -from . import config_h -from . import dfu_header -from . import docs -from . import info_json -from . import keyboard_h -from . import layouts -from . import rgb_breathe_table -from . import rules_mk diff --git a/lib/python/qmk/cli/list/__init__.py b/lib/python/qmk/cli/list/__init__.py index d83cd20b5b49..e69de29bb2d1 100644 --- a/lib/python/qmk/cli/list/__init__.py +++ b/lib/python/qmk/cli/list/__init__.py @@ -1,2 +0,0 @@ -from . import keyboards -from . import keymaps diff --git a/lib/python/qmk/cli/new/__init__.py b/lib/python/qmk/cli/new/__init__.py index fe5d6fe48371..e69de29bb2d1 100644 --- a/lib/python/qmk/cli/new/__init__.py +++ b/lib/python/qmk/cli/new/__init__.py @@ -1,2 +0,0 @@ -from . import keyboard -from . import keymap diff --git a/message.mk b/message.mk index 79d1957397ec..da5f9fb9e38b 100644 --- a/message.mk +++ b/message.mk @@ -93,3 +93,5 @@ MSG_PYTHON_MISSING = $(ERROR_COLOR)ERROR:$(NO_COLOR) Can not run \"qmk\" command MSG_FLASH_BOOTLOADER = $(WARN_COLOR)WARNING:$(NO_COLOR) This board's bootloader is not specified or is not supported by the \":flash\" target at this time.\n\n MSG_FLASH_ARCH = $(WARN_COLOR)WARNING:$(NO_COLOR) This board's architecture is not supported by the \":flash\" target at this time.\n\n MSG_BOOTLOADER_NOT_FOUND = $(ERROR_COLOR)ERROR:$(NO_COLOR) Bootloader not found. Trying again in 5s.\n +BOOTLOADER_RETRY_TIME ?= 0.5 +MSG_BOOTLOADER_NOT_FOUND_QUICK_RETRY = Bootloader not found. Trying again every $(BOOTLOADER_RETRY_TIME)s diff --git a/tmk_core/avr.mk b/tmk_core/avr.mk index 521305f1b4f4..eb934ffe6057 100644 --- a/tmk_core/avr.mk +++ b/tmk_core/avr.mk @@ -113,10 +113,16 @@ define EXEC_DFU if [ "$(1)" ]; then \ echo "Flashing '$(1)' for EE_HANDS split keyboard support." ;\ fi; \ - until $(DFU_PROGRAMMER) $(MCU) get bootloader-version; do\ - printf "$(MSG_BOOTLOADER_NOT_FOUND)" ;\ - sleep 5 ;\ - done; \ + if ! $(DFU_PROGRAMMER) $(MCU) get bootloader-version >/dev/null 2>/dev/null; then\ + printf "$(MSG_BOOTLOADER_NOT_FOUND_QUICK_RETRY)" ;\ + sleep $(BOOTLOADER_RETRY_TIME) ;\ + while ! $(DFU_PROGRAMMER) $(MCU) get bootloader-version >/dev/null 2>/dev/null; do\ + printf "." ;\ + sleep $(BOOTLOADER_RETRY_TIME) ;\ + done ;\ + printf "\n" ;\ + fi; \ + $(DFU_PROGRAMMER) $(MCU) get bootloader-version ;\ if $(DFU_PROGRAMMER) --version 2>&1 | $(GREP) -q 0.7 ; then\ $(DFU_PROGRAMMER) $(MCU) erase --force; \ if [ "$(1)" ]; then \ @@ -172,7 +178,7 @@ define EXEC_AVRDUDE TMP2=`mktemp`; \ list_devices > $$TMP1; \ while [ -z "$$USB" ]; do \ - sleep 0.5; \ + sleep $(BOOTLOADER_RETRY_TIME); \ printf "."; \ list_devices > $$TMP2; \ USB=`comm -13 $$TMP1 $$TMP2 | $(GREP) -o '/dev/tty.*'`; \ @@ -187,7 +193,7 @@ define EXEC_AVRDUDE sleep 1; \ else \ printf "Waiting for $$USB to become writable."; \ - while [ ! -w "$$USB" ]; do sleep 0.5; printf "."; done; echo ""; \ + while [ ! -w "$$USB" ]; do sleep $(BOOTLOADER_RETRY_TIME); printf "."; done; echo ""; \ fi; \ if [ -z "$(1)" ]; then \ $(AVRDUDE_PROGRAMMER) -p $(MCU) -c avr109 -P $$USB -U flash:w:$(BUILD_DIR)/$(TARGET).hex; \ diff --git a/tmk_core/chibios.mk b/tmk_core/chibios.mk index cdf9ba6495c0..97299b7d324e 100644 --- a/tmk_core/chibios.mk +++ b/tmk_core/chibios.mk @@ -341,10 +341,15 @@ ST_LINK_CLI ?= st-link_cli ST_FLASH ?= st-flash define EXEC_DFU_UTIL - until $(DFU_UTIL) -l | grep -q "Found DFU"; do\ - printf "$(MSG_BOOTLOADER_NOT_FOUND)" ;\ - sleep 5 ;\ - done + if ! $(DFU_UTIL) -l | grep -q "Found DFU"; then \ + printf "$(MSG_BOOTLOADER_NOT_FOUND_QUICK_RETRY)" ;\ + sleep $(BOOTLOADER_RETRY_TIME) ;\ + while ! $(DFU_UTIL) -l | grep -q "Found DFU"; do \ + printf "." ;\ + sleep $(BOOTLOADER_RETRY_TIME) ;\ + done ;\ + printf "\n" ;\ + fi $(DFU_UTIL) $(DFU_ARGS) -D $(BUILD_DIR)/$(TARGET).bin endef diff --git a/users/mnil/config.h b/users/mnil/config.h new file mode 100644 index 000000000000..3547785ff78c --- /dev/null +++ b/users/mnil/config.h @@ -0,0 +1,21 @@ +/* Copyright 2021 Mats Nilsson + * + * 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 MK_3_SPEED +#define MK_MOMENTARY_ACCEL +#define PERMISSIVE_HOLD diff --git a/users/mnil/mnil.c b/users/mnil/mnil.c new file mode 100644 index 000000000000..11d5ee28dfa2 --- /dev/null +++ b/users/mnil/mnil.c @@ -0,0 +1,146 @@ +/* Copyright 2021 Mats Nilsson + * + * 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 "mnil.h" + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case M_TILD: // ~ + if (record->event.pressed) { + tap_code16(RALT(KC_RBRC)); + tap_code(KC_SPC); + } else { + } + break; + case M_CIRC: // ^ + if (record->event.pressed) { + tap_code16(S(KC_RBRC)); + tap_code(KC_SPC); + } else { + } + break; + case M_BTCK: // ` + if (record->event.pressed) { + tap_code16(S(KC_EQL)); + tap_code(KC_SPC); + } else { + } + break; + case QWE_COL: // Swap default keymap layer + if (record->event.pressed) { + if (get_highest_layer(default_layer_state) == _COLEMAK) { + default_layer_set(1UL << _QWERTY); + } else { + default_layer_set(1UL << _COLEMAK); + } + } + break; + } + return true; +}; + +// Tap Dance +// Determine the current tap dance state +int cur_dance(qk_tap_dance_state_t *state) { + if (state->count == 1) { + if (state->interrupted || !state->pressed) + return SINGLE_TAP; + else + return SINGLE_HOLD; + } else if (state->count == 2) { + if (state->interrupted) + return DOUBLE_SINGLE_TAP; + else if (state->pressed) + return DOUBLE_HOLD; + else + return DOUBLE_SINGLE_TAP; + } + if (state->count == 3) { + if (state->interrupted || !state->pressed) + return TRIPLE_TAP; + else + return TRIPLE_HOLD; + } else + return 8; +} + +static tap ae_tap_state = {.is_press_action = true, .state = 0}; + +void ae_finished(qk_tap_dance_state_t *state, void *user_data) { + ae_tap_state.state = cur_dance(state); + switch (ae_tap_state.state) { + case SINGLE_TAP: + register_code(KC_A); + break; + case SINGLE_HOLD: + tap_code(SE_AE); + break; + case DOUBLE_SINGLE_TAP: + tap_code(KC_A); + register_code(KC_A); + break; + } +} + +void ae_reset(qk_tap_dance_state_t *state, void *user_data) { + switch (ae_tap_state.state) { + case SINGLE_TAP: + unregister_code(KC_A); + break; + case DOUBLE_SINGLE_TAP: + unregister_code(KC_A); + break; + } + ae_tap_state.state = 0; +} + +static tap aa_tap_state = {.is_press_action = true, .state = 0}; + +void aa_finished(qk_tap_dance_state_t *state, void *user_data) { + aa_tap_state.state = cur_dance(state); + switch (aa_tap_state.state) { + case SINGLE_TAP: + register_code(SE_OSLH); + break; + case SINGLE_HOLD: + register_code(SE_AA); + unregister_code(SE_AA); + break; + case DOUBLE_SINGLE_TAP: + tap_code(SE_OSLH); + register_code(SE_OSLH); + break; + } +} + +void aa_reset(qk_tap_dance_state_t *state, void *user_data) { + switch (aa_tap_state.state) { + case SINGLE_TAP: + unregister_code(SE_OSLH); + break; + case DOUBLE_SINGLE_TAP: + unregister_code(SE_OSLH); + break; + } + aa_tap_state.state = 0; +} + +// clang-format off +qk_tap_dance_action_t tap_dance_actions[] = { + [AAE] = ACTION_TAP_DANCE_FN_ADVANCED_TIME(NULL, ae_finished, ae_reset, 250), + [OAA] = ACTION_TAP_DANCE_FN_ADVANCED_TIME(NULL, aa_finished, aa_reset, 250) +}; +// clang-format on diff --git a/users/mnil/mnil.h b/users/mnil/mnil.h new file mode 100644 index 000000000000..357acfe3ce31 --- /dev/null +++ b/users/mnil/mnil.h @@ -0,0 +1,85 @@ +/* Copyright 2021 Mats Nilsson + * + * 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 QMK_KEYBOARD_H +#include "keymap_swedish.h" + +// Layers +enum layers { + _COLEMAK, + _QWERTY, + _SYMBOLS, + _NAVIGATION, + _NUMPAD, +}; + +// Custom Keycodes +#define _NAV_SPC LT(_NAVIGATION, KC_SPC) // _NAVIGATION when held, SPACE when tapped +#define _SYM_ENT LT(_SYMBOLS, KC_ENT) // _SYMBOLS when held, ENTER when tapped +#define CTL_BSPC MT(MOD_LCTL, KC_BSPC) // CTRL when held, BACKSPACE when tapped +#define ALT_DEL MT(MOD_LALT, KC_DEL) // ALT when held, DELETE when tapped +#define SFT_TAB MT(MOD_LSFT, KC_TAB) // SHIFT when held, TAB when tapped +#define C_TAB C(KC_TAB) // CTRL+TAB +#define CS_TAB C(S(KC_TAB)) // SHIFT+CTRL+TAB +#define CUT C(KC_X) // CTRL+X +#define COPY C(KC_INS) // CTRL+INSERT +#define PASTE S(KC_INS) // SHIFT+INSERT +#define AUTOFILL C(S(KC_L)) // Bitwarden Autofill, CTRL+SHIFT+L + +// i3 config +#define I3MOD KC_LGUI // $mod +#define OPEN G(KC_SPC) // $mod+SPACE +#define QUIT G(S(KC_Q)) // $mod+SHIFT+Q +#define WIN G(C(KC_SPC)) // $mod+CTRL+SPACE +#define BROWSER G(KC_ENTER) // $mod+ENTER +#define TERM G(S(KC_ENTER)) // $mod+CTRL+ENTER +#define NXTWS G(KC_TAB) // $mod+TAB +#define PRVWS G(S(KC_TAB)) // $mod+SHIFT+TAB +#define MOVWS G(KC_LSFT) // $mod+SHIFT+$X +#define CRYWS G(KC_LALT) // $mod+ALT+$X +#define MVWSL G(C(S(KC_LEFT))) // $mod+CTRL+SHIFT+LEFT +#define MVWSR G(C(S(KC_RGHT))) // $mod+CTRL+SHIFT+RIGHT + +enum custom_keycodes { + M_TILD = SAFE_RANGE, // ~ + M_CIRC, // ^ + M_BTCK, // ` + QWE_COL, // Swaps default layer +}; + +// Tap Dance +typedef struct { + bool is_press_action; + int state; +} tap; + +// Define a type for as many tap dance states as you need +enum { + SINGLE_TAP = 1, + SINGLE_HOLD = 2, + DOUBLE_TAP = 3, + DOUBLE_HOLD = 4, + DOUBLE_SINGLE_TAP = 5, // send two single taps + TRIPLE_TAP = 6, + TRIPLE_HOLD = 7 +}; + +enum { + AAE = 0, // a and ae + OAA, // o and aa +}; diff --git a/users/mnil/readme.md b/users/mnil/readme.md new file mode 100644 index 000000000000..f688ea388adf --- /dev/null +++ b/users/mnil/readme.md @@ -0,0 +1,23 @@ +# mnil's user settings +This keymap consist of four primary layers, `_COLEMAK`, `_SYMBOL`, `_NAVIGATION` and `_NUMPAD`. +Colemak layout for less finger travel distance and to reduce RSI. +The `_SYMBOL` layer is optimized for programming, specifically in `C++`. +Space and Enter do double duties as layer toggle on hold where the `_NUMPAD` is entered when both are held down. +`ALT+TAB` and `SHIFT+ALT+TAB` keys is implemented to register `ALT` and then `TAB` on each subsequent key press one leaves the `_NUMPAD`-layer. +The Swedish characters `åäöÅÄÖ` are added as a tap dances on top of the Colemak layer since they are rarely needed. + +# License +Copyright 2021 Mats Nilsson matni403@gmail.com @mnil + +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 . diff --git a/users/mnil/rules.mk b/users/mnil/rules.mk new file mode 100644 index 000000000000..22cebfaeebe8 --- /dev/null +++ b/users/mnil/rules.mk @@ -0,0 +1,7 @@ +SRC += mnil.c +MOUSEKEY_ENABLE = yes # Enable mouse keys +LTO_ENABLE = yes # Enable link time optimization +BACKLIGHT_ENABLE = no +CONSOLE_ENABLE = no +AUTO_SHIFT_ENABLE = no +TAP_DANCE_ENABLE = yes diff --git a/util/install/debian.sh b/util/install/debian.sh index 380348237ae9..9e1299697674 100755 --- a/util/install/debian.sh +++ b/util/install/debian.sh @@ -15,7 +15,7 @@ _qmk_install() { build-essential clang-format diffutils gcc git unzip wget zip \ python3-pip binutils-avr gcc-avr avr-libc binutils-arm-none-eabi \ gcc-arm-none-eabi libnewlib-arm-none-eabi avrdude dfu-programmer \ - dfu-util teensy-loader-cli libhidapi-hidraw0 + dfu-util teensy-loader-cli libhidapi-hidraw0 libusb-dev python3 -m pip install --user -r $QMK_FIRMWARE_DIR/requirements.txt }