Skip to the content
2 layers133.1 × 47 mmMacropad, the printed circuit board in 3D

This repository contains the complete hardware design and firmware for a custom, fully functional buillt macropad based on the Seeed Studio XIAO RP2040 microcontroller.

Size
133.1 × 47 mm
Copper layers
2
Thickness
1.6 mm
Parts
9
Nets
18
Pads
42
Tracks, vias
58, 0
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
17 Jul 2026
Updated
21 Jul 2026

Overview

Macropad is an open-source printed circuit board by yansha2903-bot, from the yansha2903-bot/Macropad repository on GitHub, published under the MIT licence. It is a 2-layer board of 133.1 × 47 mm with 9 parts on 18 nets, routed with 58 tracks and 0 vias.

It is built around the 1N4148W. Its parts include 4 diodes, 4 switches and 1 IC. It belongs with the keyboards and input boards and the RP2040 boards of this library.

Main components

1

README

README.md

Custom 4-Key Macropad

This repository contains the complete hardware design and firmware for a custom, fully functional buillt macropad based on the Seeed Studio XIAO RP2040 microcontroller.


Repository Structure

  • KiCad — KiCad project files:
  • *.kicad_pro — KiCad project configuration.
  • *.kicad_sch — Electrical schematic.
  • *.kicad_pcb — Custom PCB routing and layout.
  • *Macropad-DrillFiles.zip - Drill files.
  • *Macropad-Gerbers.zip - Gerbers.
  • Firmware/ — Microcontroller source code:
  • *.ino — Arduino IDE sketch for USB-HID keyboard emulation.
  • Images - Images of my project.
  • License - MIT License.

Hardware Features

  • Microcontroller: Seeed Studio XIAO RP2040 (running as a USB-HID keyboard).
  • Switches: 4x mechanical Cherry MX style switches aligned in a horizontal row.
  • Diodes: 4x SMD 1N4148 (SOD-123) diodes to prevent ghosting during multi-key presses.
  • Custom PCB Design: The board shape features custom geometric triangular "ears" on the top edge of the Edge.Cuts layer.
  • Pinout Configuration:
  • Switch Inputs: Connected to digital pins D0, D1, D2, and D3.
  • Common Diode Return: Connected to digital pin D9.

Firmware Details

The firmware is written in C++ using the Arduino IDE and the native <Keyboard.h> library.

Key Functionality:

  • USB-HID Emulation: The computer automatically recognizes the macroplat as a standard USB keyboard without external drivers.
  • State Tracking: Uses a state array to compare the current state of each switch to its previous state, preventing duplicate inputs.
  • Debounce Filter: Features a 15ms software delay to filter out mechanical contact noise.
  • Default Keymap: Mapped to output characters '1', '2', '3', and '4' respectively.
2026-07-17_15-21-05 2026-07-17_15-32-29

Parts

9
QtyValueFootprintReferences
41N4148WDiode_SMD:D_SOD-123D1, D2, D3, D4
4SW_PushButton_Switch_Keyboard:SW_Cherry_MX_1.00u_PCBSW1, SW2, SW3, SW4
1XIAO-RP2040-DIPPackage_DIP:DIP-14_W7.62mmU1

Similar boards

  • 4 layers99 × 53.3 mmPSLab, the printed circuit board in 3D

    PSLab

    fossasia/pslab-hardware

    PSLab Hardware Design and Schematics https://pslab.io

    199 parts1.7kApache-2.0
  • 2 layers208.8 × 396.9 mmFerris, the printed circuit board in 3D

    Ferris

    pierrechevalier83/ferris

    A low profile split keyboard designed to satisfy one single use case elegantly

    145 parts1.3k
  • 2 layers285.5 × 95 mmReviung46 ver1 1, the printed circuit board in 3D

    Reviung46 ver1 1

    gtips/reviung

    The REVIUNG41 is 41-key column staggered keyboard.

    119 parts517MIT
  • 4 layers95.6 × 73.6 mmMathpad, the printed circuit board in 3D

    Mathpad

    Summa-Cogni/Mathpad

    A mathematical keypad for students and professionals

    93 parts243
  • 2 layers141.5 × 83 mmRolio, the printed circuit board in 3D

    Rolio

    MickiusMousius/Rolio46Keyboard

    A split wireless keyboard based on the Corne and Sofle

    110 parts236MIT
  • 6 layers160 × 100 mmAdrmu6layer, the printed circuit board in 3D

    Adrmu6layer

    marcoreps/ADRmu

    ADR1000 10V standard

    240 parts149
  • 2 layers99.1 × 90.7 mmBgkeeb, the printed circuit board in 3D

    Bgkeeb

    sadekbaroudi/bgkeeb

    This is a reversible 100mm x 100mm pcb with support for mx or choc switches (no hotswap), per key led, rotary encoders, and exposes the SDA/SCL/GND/VCC lines in the form of the pimoroni trackball pins (meaning you can…

    108 parts108
  • 2 layers229.8 × 102.6 mmBw2, the printed circuit board in 3D

    Bw2

    hazels-garage/bad-wings

    Bad Wings

    107 parts107CC-BY-SA-4.0

Questions

How big is the Macropad PCB?

It measures 133.1 × 47 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Macropad use?

9 parts, built around the 1N4148W. 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 Macropad KiCad files?

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

Can I use the Macropad design in my own project?

Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).