Skip to the content
2 layersKey, the printed circuit board in 3D

key.kicadsch の 4 行 × 3 列スイッチを読み取り、USB HID Boot Keyboard として入力するファームウェアです。CDC シリアルも複合デバイスのまま残し、参照実装と同じ 1200 bps touch → BootROM 書き込みを使用します。スケッチは firmware/keypad/keypad.ino、ボードパッケージは hardware/key/ch32x035f7p6/ です。

Copper layers
2
Thickness
1.6 mm
Parts
40
Nets
37
Pads
155
Tracks, vias
335, 48
Pours
2
Routed
Yes
KiCad
KiCad 9.0 (file 20241229)
Created
7 Sep 2026
Updated
23 Sep 2026

Overview

Key is an open-source printed circuit board by kannakanna1, from the kannakanna1/key repository on GitHub. It is a 2-layer board with 40 parts on 37 nets, routed with 335 tracks and 48 vias.

It is built around the CH32X035F7P6 and EVPAWCD40. Its parts include 14 switches, 13 diodes, 6 resistors, 3 capacitors and 2 ICs.

Main components

2

README

README.md

CH32X035 12キー USB キーパッド

key.kicad_sch の 4 行 × 3 列スイッチを読み取り、USB HID Boot Keyboard として入力するファームウェアです。CDC シリアルも複合デバイスのまま残し、参照実装と同じ 1200 bps touch → BootROM 書き込みを使用します。スケッチは firmware/keypad/keypad.ino、ボードパッケージは hardware/key/ch32x035f7p6/ です。

配線とキー

col1 PA0col2 PA1col3 PA2
row1 PA3SW1: 0SW5: 1SW9: 2
row2 PA4SW2: 3SW6: 4SW10: 5
row3 PA5SW3: 6SW7: 7SW11: 8
row4 PA6SW4: 9SW8: ASW12: B

列は順番に LOW 駆動し、非選択列は高インピーダンス、行はプルアップ入力です。ダイオードは行側がアノード・列側がカソード。約 5 ms のデバウンス、最大 6 キー同時押し、8 byte Boot Keyboard レポートを使用します。0–9 は NumLock に依存しない通常の数字キー、A/B は英字キーです(大文字になるかはホストの Shift/Caps Lock 次第)。配列 keys を変更すれば HID Usage を変更できます。PC3 は操作しません。回路図では LED のカソードが VDD 側で逆方向のため、ソフトウェアだけでは点灯できません。PC18/19 の SWD、PC14–17 の USB には触れません。SW40 は USB D+ 側の回路、SW41 はリセットであり、キー配列には含みません。

Arduino IDE / CLI

このリポジトリのボードパッケージは ch32x035f7p6-micro-devboard の Arduino コア・起動処理・GPIO・USB CDC・アップロードツールをコピーしたものです。HID 複合デバイス対応だけ cores/arduino/ch32x_cdc.c を拡張しています。通常の Micro Devboard ボードではなく、必ず CH32X035F7P6 Keypad を選択してください (FQBN key:ch32x035f7p6:ch32x035f7p6)。USB ID は参照 CDC 専用版の 1A86:FE0C と区別して 1A86:FE0D です(試作用 ID。製品化時は正規の VID/PID に変更すること)。

Windows

  1. 参照リポジトリの setup.bat / setup.ps1 を実行し、ツールチェイン・wchisp・WCH ISP ドライバをインストールします。
  2. このリポジトリで powershell.exe -NoProfile -ExecutionPolicy Bypass -File .\install.ps1 を実行します。スケッチブックが標準パス以外なら -Sketchbook D:\Arduino を指定します。Arduino IDE を再起動します。
  3. IDE でボード CH32X035F7P6 Keypad と CDC ポートを選択し、firmware/keypad/keypad.ino を開いて Verify / Upload します。CLI なら以下のコマンドを使えます。

Linux

参照リポジトリの PlatformIO CH32 用 toolchain (~/.platformio/packages/toolchain-riscv/bin) と wchisp を用意し、./install.sh を実行します。インストール先は既定で ~/Arduino/hardware/key/ch32x035f7p6 です。別のスケッチブック・ツールチェインなら ./install.sh /path/to/sketchbook /path/to/toolchain/bin と指定します。Python 3 と wchisp を PATH に配置してください。

sh
arduino-cli compile --fqbn key:ch32x035f7p6:ch32x035f7p6 firmware/keypad
arduino-cli upload -p /dev/ttyACM0 --fqbn key:ch32x035f7p6:ch32x035f7p6 firmware/keypad

初回(CDC ファームウェア未書き込み)や BootROM 起動済みの場合は -p none でアップロードするか、参照ボードと同じ wch-link / WCH ISP の手順で初回書き込みを行ってください。実機の Arduino CLI 書き込み・検証と USB 複合デバイス列挙(cdc_acm / usbhid)を確認済みです。実キーの押下動作は未確認です。

Parts

40
QtyValueFootprintReferences
121N4148Diode_THT:D_DO-35_SOD27_P7.62mm_HorizontalD1, D2, D3, D4, D5, D6, D7, D8, D9, D10, D11, D12
12SW_MEC_5GButton_Switch_Keyboard:SW_Cherry_MX_1.00u_PCBSW1, SW2, SW3, SW4, SW5, SW6, SW7, SW8, SW9, SW10, SW11, SW12
35k1Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR1, R2, R5
210u/35VCapacitor_THT:CP_Radial_Tantal_D5.5mm_P5.00mmC1, C2
222Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR3, R4
2EVPAWCD40Button_Switch_THT:SW_PUSH_6mmSW40, SW41
10.1u/50VCapacitor_THT:CP_Radial_Tantal_D5.5mm_P5.00mmC3
11kResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR6
1CH32X035F7P6Package_SO:TSSOP-20_4.4x6.5mm_P0.65mmU1
1NJM78L33SU3Package_TO_SOT_SMD:SOT-89-3U2
1Red_LEDLED_THT:LED_D3.0mmD40
1SWDIOConnector_PinHeader_2.54mm:PinHeader_1x04_P2.54mm_VerticalJ2
1USB_C_ReceptacleDownload_Lib:USB-C_16-HandSolderJ1

Similar boards

  • 2 layers20.3 × 50.8 mmRp2354a micro devboard, the printed circuit board in 3D

    Rp2354a micro devboard

    esehehelp/rp2354a_micro_devboard

    rp2354a micro devboard

    65 partsMIT
  • 2 layers85.6 × 54 mmBusiness Card v2, the printed circuit board in 3D

    Business Card v2

    SattiDaBeaver/Business_Card_v2

    RISC-V supercluster PCB business card with 1 master + 8 worker MCUs over a shared UART bus, USB-C edge connector

    183 parts1
  • 2 layers95 × 30 mmTsubaki lite, the printed circuit board in 3D

    Tsubaki lite

    ametou/tsubaki_lite

    4key+knob ortholinear osu! keyboard w/ individual LED, powered by CH32X035. With reference to https://github.com/rgoulter/keyboard-labs

    39 partsCERN-OHL-W-2.0
  • 2 layers53 × 69 mmVu meter processor, the printed circuit board in 3D

    Vu meter processor

    radioegor146/vu-meter

    Physical VU meter for use with rack audio equipment

    54 parts
  • 2 layers139.7 × 73.7 mm134pin 7-967288-1, the printed circuit board in 3D

    134pin 7-967288-1

    rusefi/rusefi

    rusefi - GPL internal combustion engine control unit

    40 parts1.2k
  • 2 layers149.4 × 177.4 mmLightsculpture, the printed circuit board in 3D

    Lightsculpture

    hackclub/OnBoard

    💡 Join 1,000 teenagers and make your first PCB with a $100 grant!

    40 parts915
  • 2 layers150 × 50 mmEleLab v2 Bus150, the printed circuit board in 3D

    EleLab v2 Bus150

    Chrismettal/EleLab_v2

    Cheap DIY lab system for hobbyists and the tinkering folk

    40 parts531GPL-3.0

Questions

What parts does the Key use?

40 parts, built around the CH32X035F7P6 and EVPAWCD40. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the Key KiCad files?

From the kannakanna1/key repository on GitHub, at the commit this page was made from: the board is key.kicad_pcb and its schematic key.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Key design in my own project?

Its repository states no licence, so its author keeps all rights: ask kannakanna1 before reusing the design.