Skip to main content

Firmware ↔ rev H pin map

Defines live in toern.ino. Net names below match the rev H netlist (PCB/toern_revH/toern_revH.net). The schematic PDF wins if a silk label disagrees.

Core defines​

FirmwareTeensy pinBoard use
DATA_PIN17WS2812 data. Series R20 (220 Ω) then J9 pin 1
INT_PIN27Shared encoder interrupt (pad 5 on encoder sockets)
INT_SD10microSD chip-select
SWITCH_12Touch / TTP223 — single mode
SWITCH_23Touch — menu
SWITCH_34Touch — record
SWITCH_46Extra switch net (board-dependent)
SWITCH_539Extra switch net (board-dependent)
BATT_ADC_PINA16 (40)VBAT divider

MIDI on Serial8 uses pins 34/35 (RX8/TX8) with enlarged buffers — TRS jacks go through the opto / buffer stage (TLP2361 U4, Schmitt 74LVC2G14 U5).

Buses (by convention)​

BusPinsDevices
I²C018 / 19Encoders + SGTL5000 control
SPI (SD)10–13microSD J8
I²S (codec)(Audio library defaults on Teensy 4 + SGTL wiring)U3 data/clocks — see schematic
USBD+/D− pads on U6USB-C J4 via pogo pins CN1 (D−) and CN2 (D+)

When changing pins​

  1. Update the PCB net / jumper and the #defines.
  2. Re-check encoder INT (must be common open-drain style as wired).
  3. Re-check SD CS vs any other SPI CS uses.
  4. Battery divider in firmware must match the assembled resistors. On rev H that is R15 1 MΩ (VBAT → A16) and R19 1.5 MΩ (A16 → GND).