Module for 25 switches (button matrix)

September 3, 2025 ยท View on GitHub

Module for 25 switches (through-hole)

Note

This board has been manufactured and tested (REV2). It works.

Features

  • 25 external switches.
  • Through-hole mounting.
  • No common pole for switches.
  • Based on a button matrix: 5 selector and 5 input pins.

Parts

This PCB is designed to assemble the components yourself using basic tools. Thus, you only need to order the fabrication of the board as the price is much lower.

  • Diodes (mandatory): x25

    • Any Schottky type diode with low forward voltage can be used. The 1N4148 brand is recommended.
  • Bended male Dupond headers (optional)

    You can also solder the wires directly to the board.

    • 2x12P (24 pins): x2
    • 2x6P (12 pins): x1

Manufacturing

This PCB was designed using Easy EDA Pro. If you want to order a PCB to their prototyping service, take into account that the components are not included in the bill of materials (BOM). You will receive an error message regarding those. To include them, edit the schematic, select a component (grayed out) and set the property "Add into BOM" to "true".

Link to project in Open Source Hardware Labs: https://oshwlab.com/afpineda/module25switches_th_matrix. You can one-click order manufacturing from that site.

PCB manufacturing details:

  • 2 layers.
  • Default physical stacking (there are no choices).
  • FR-4 base material (the cheapest, but you may choose another).
  • Vias:
    • Minimum hole size is 0.3 mm.
    • Minimum ring diameter is 0.4 mm.
    • Use the cheapest covering.
  • Copper weight: 1oz.

Files

  • Easy EDA Pro

    Some parts designed but not included in the BOM. Note: you can import this file to KiCAD 9 or later.

  • Bill of materials

    Note: not needed unless you want to order parts to the manufacturer.

  • Pick and place

    Note: not needed unless you want to order mounting to the manufacturer.

  • Schematic

  • GERBER

Assembly

Pay attention to the orientation of the diodes, which is printed in the front side. Place the diodes in vertical position, so they lay in a minimal surface of the board.

External wiring

  • Wire the switches in columns to the lateral headers, except for S0I0, which is placed in the first column of the central header.

  • Wire one screw to GND to provide shielding (optional).

  • The button matrix is designed to work in positive logic. If you swap the selector and input pins, it works in negative logic.

The pin out should be printed in the back of the board.

  • Selector pins are tagged as S<n>.
  • Input pins are tagged as I<n>.
  • Each switch is tagged as S<a>I<b>, which means that it is attached to S<a> and I<b>.

Pin out

Usage

See the button matrices in the switches subsystem.