Skip to the content
2 layers340 × 100 mmSwitchplate, the printed circuit board in 3D

hardware-based step sequencer using the Teensy 4.1 microcontroller

Size
340 × 100 mm
Copper layers
2
Thickness
1.6 mm
Parts
9
Nets
9
Pads
80
Tracks, vias
27, 0
Pours
1
Routed
Yes
KiCad
KiCad 9.0 (file 20241229)
Created
24 Jan 2026
Updated
3 Oct 2026

Overview

Switchplate is an open-source printed circuit board by dwmorrin, from the dwmorrin/teensy-step-sequencer repository on GitHub. It is a 2-layer board of 340 × 100 mm with 9 parts on 9 nets, routed with 27 tracks and 0 vias.

README

README.md

Teensy Step Sequencer

This project implements a hardware-based step sequencer using the Teensy 4.1 microcontroller. It utilizes the Teensy's onboard USB Host capabilities to accept input from standard USB keyboards, alongside a custom 32-switch diode matrix for tactile control.

Gallery

Version 1 first build

Version 1 first build

Prototype

Breadboard Setup

Hardware Renders

Main BoardSwitchplate
Main Board RenderSwitchplate Render

System Overview

The application is designed as a standalone, embedded instrument. It functions as an 8-track step sequencer with support for 96 PPQN high-resolution timing, pattern chaining (Song Mode), per-track swing, real-time performance triggers, and visual feedback via an I2C OLED display with scrolling track views.

Hardware Dependencies

  • Microcontroller: Teensy 4.1 (Selected for native USB Host and RAM capacity).
  • Display: - 1.3" SH1106 OLED (I2C) for the graphical interface.
    • 16x LEDs driven by 74HC595 Shift Registers for step visualization.
  • Input: - Standard USB HID Keyboard (via USB Host).
    • 4x8 Diode Matrix Keyboard (32 switches).
    • 2x Analog Potentiometers (Tempo and Parameter control).
  • Output: 8x 5V Logic Triggers (GPIO).

Software Architecture

The codebase adopts a modular architecture separating data, presentation, and hardware control. The source code located in src/ is organized into the following domains:

  • Model (src/Model/) This directory contains the core logic and data structures. It serves as the single source of truth for the application, managing the Pattern Pool, the Playlist (Song Mode), Swing parameters, and the Undo buffer. The Model is decoupled from hardware; it does not know if it is being driven by a clock or edited by a keyboard.

  • View (src/View/) This directory handles all visual output.

    • DisplayManager: Observes the Model and renders the interface (Grid, Transport, Headers) to the OLED. It handles viewport scrolling to display 8 tracks on a 4-track height screen.
    • StepLeds: Manages the 16-step LED array via SPI shift registers. The view layer includes internal throttling logic to maintain a consistent frame rate without blocking the audio/timing threads.
  • Controller (src/Controller/) This directory manages user input and state routing. The UIManager aggregates inputs from multiple hardware sources:

    • USB Keyboard: Handled via the Teensy USBHost_t36 library.
    • Matrix: Handled by KeyMatrix, a custom driver for scanning the 4x8 diode array.
    • Analog: Handled by AnalogInput, which provides hysteresis and signal smoothing for potentiometers.

    Inputs are translated into abstract InputCommands (e.g., CMD_TRANSPORT_TOGGLE), decoupling the physical control method from the internal application logic.

  • Engine (src/Engine/) This directory handles real-time operations.

    • ClockEngine: A 96 PPQN (Pulses Per Quarter Note) interrupt-driven engine. It calculates micro-timing for Swing and groove effects, offering 24 "ticks" per 16th-note step.
    • OutputDriver: Abstraction layer for the physical hardware. It converts track bitmasks into GPIO signals using high-precision interrupt timers.
  • Configuration (src/Config.h) A global header file defining build-time constraints, including track count, pattern limits, pin mappings, and signal polarity.

Expansion Guidelines

The system is designed to be extensible. Developers looking to expand functionality should consider the following architectural patterns:

Persistence (SD Card Storage)

Current pattern data is stored in volatile RAM and is lost upon power cycle. The Teensy 4.1 includes a native micro-SD card slot. Future development should implement a PersistenceManager class. This component should:

  1. Serialize the SequencerModel data structures (Pattern Pool and Playlist) into a binary or JSON format.
  2. Write to the SD card using the standard Arduino SD library.
  3. Interface with the UIManager to allow loading and saving of projects.

Timing Calculation

The system timing is based on a standard 4/4 time signature where a "beat" represents a quarter note.

The engine runs at 96 PPQN resolution. The interval $T$ (milliseconds per tick) is calculated as:

$$T = \frac{60,000}{BPM \times 96}$$

For a standard trigger pulse width of 15ms, the system manages overlapping triggers via a pulse-counter in the interrupt service routine.

Parts

9
QtyValueFootprintReferences
8AudioJack2Connector_Audio:Jack_3.5mm_CUI_SJ1-3523N_HorizontalJ1, J2, J3, J4, J5, J6, J7, J8
1Conn_02x08_Odd_EvenConnector_PinHeader_2.54mm:PinHeader_2x08_P2.54mm_VerticalJ9

More from dwmorrin/teensy-step-sequencer

1
  • 2 layers340 × 100 mmTeensy step sequencer, the printed circuit board in 3D

    Teensy step sequencer

    dwmorrin/teensy-step-sequencer

    hardware-based step sequencer using the Teensy 4.1 microcontroller

    151 parts

Similar boards

  • 2 layers103 × 30.5 mmTS Back Endcap, the printed circuit board in 3D

    TS Back Endcap

    EEVengers/ThunderScope

    ThunderScope GitHub Repo

    9 parts1.3kMIT
  • 2 layers31.8 × 47.6 mmNGC 38 connector, the printed circuit board in 3D

    NGC 38 connector

    rusefi/rusefi

    rusefi - GPL internal combustion engine control unit

    9 parts1.2k
  • 2 layers24 × 27.3 mmExpansion Card Retrofit, the printed circuit board in 3D

    Expansion Card Retrofit

    FrameworkComputer/ExpansionCards

    Reference designs and documentation to create Expansion Cards for the Framework Laptop

    9 parts1.1kCC-BY-4.0
  • 2 layers15.6 × 17.3 mmSKR Mini TFT Thermistor Board, the printed circuit board in 3D

    SKR Mini TFT Thermistor Board

    VoronDesign/Voron-Hardware

    Cool Hardware designed by the Voron Design group

    9 parts1.1kGPL-3.0
  • 2 layers39.1 × 49.5 mmLearnoliver, the printed circuit board in 3D

    Learnoliver

    hackclub/OnBoard

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

    9 parts915
  • 2 layers17.4 × 16.9 mmToolhead, the printed circuit board in 3D

    Toolhead

    tanaes/whopping_Voron_mods

    9 parts787GPL-3.0
  • 2 layers9.8 × 108 mmExpander, the printed circuit board in 3D

    Expander

    wntrblm/Castor_and_Pollux

    A Juno-inspired dual oscillator

    9 parts587
  • 2 layersKeyboard after, the printed circuit board in 3D

    Keyboard after

    adamws/kicad-kbplacer

    KiCad plugin for automatic keyboard's key placement and routing

    9 parts547GPL-3.0

Questions

How big is the Switchplate PCB?

It measures 340 × 100 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Switchplate use?

9 parts. 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 Switchplate KiCad files?

From the dwmorrin/teensy-step-sequencer repository on GitHub, at the commit this page was made from: the board is switchplate/switchplate.kicad_pcb and its schematic hardware/teensy-step-sequencer.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Switchplate design in my own project?

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