Skip to the content
2 layers372.9 × 100.8 mmKeyboard, the printed circuit board in 3D

One main keyboard ("parent") with magnetic dock connectors on its edges, and detachable macropads ("children") that either run standalone on their own USB-C or dock to the parent as passive matrix extensions.

Size
372.9 × 100.8 mm
Copper layers
2
Thickness
1.6 mm
Parts
433
Nets
244
Pads
1,525
Tracks, vias
234, 0
Routed
Yes
KiCad
KiCad 9.0 (file 20241229)
Created
16 Aug 2026
Updated
7 Sep 2026

Overview

Keyboard is an open-source printed circuit board by JoniBach, from the JoniBach/bachro-board-v1 repository on GitHub. It is a 2-layer board of 372.9 × 100.8 mm with 433 parts on 244 nets, routed with 234 tracks and 0 vias.

It is built around the SK6812MINI-E. Its parts include 216 diodes, 108 capacitors and 108 switches. It belongs with the keyboards and input boards of this library.

Main components

1

README

README.md

bach-board-v1 — Modular Dock Keyboard System

One main keyboard ("parent") with magnetic dock connectors on its edges, and detachable macropads ("children") that either run standalone on their own USB-C or dock to the parent as passive matrix extensions. Supersedes the TRRS-linked two-piece split concept (keebach-narrow-v1) and formalizes the tether/dock behavior bachro-pad-v1's firmware only partially implements today.

Bootstrapped from https://editor.keyboard-tools.xyz/. Sub-projects, as currently laid out:

FolderRoleLayout
ba-choreParent board's core key block~60-key QWERTY, standard rows
ba-chropadChild macropad4 rotary encoders + 6x4 (24-key) grid: nav cluster, NUM toggle, layer key
ba-chroboardComposite reference layoutba-chore's block flanked by two mirrored 4-encoder clusters (left + right) — a preview of the parent with a macropad docked on each side, not a single fused PCB

(Mapping inferred from each folder's keyboard/keyboard.json KLE export — correct if any of these are mislabeled.)

Domain model

Entities

  • Board (abstract) — RP2040, own USB-C, own key matrix, own local I2C bus (private, drives its own OLED + any local peripherals). Two concrete kinds:
    • ParentBoard (ba-chore) — exactly one per system. N DockConnectors along its edges (baseline: 2, LEFT/RIGHT, per the ba-chroboard reference layout).
    • ChildBoard (ba-chropad) — a macropad. Connector footprints for docking to the parent, with landscape rotation and chaining support (see FR8/FR11).
  • DockConnector — 4-conductor magnetic pogo interface: GND, VCC, SDA, SCL. Power flows parent→child only; I2C is bidirectional.
  • BoardMode (per-board runtime state):
    • STANDALONE — own USB-C cable present. Full local operation: own matrix → own USB HID, own OLED live off the local bus.
    • DOCKED_SLAVE (children only) — no own cable, dock contact present. The RP2040's connector-facing I2C interface (I2C1) runs in slave mode, exposing raw matrix (+ encoder) state only. Zero HID/host decisions. OLED stays live — it's on the local bus (I2C0), unaffected by slave mode on the connector-facing bus.
    • PARENT_MASTER (parent only, implicit whenever parent is cabled) — not a separate mode from the parent's perspective; polling whatever's docked is just part of normal operation.
  • Mode resolution rule: own-cable presence always wins → STANDALONE. No cable + dock contact → DOCKED_SLAVE. No cable + no dock contact → unpowered (children have no other power source; this is also how dock-detect works for a child — booting at all is the detect event, no dedicated sense pin needed).
  • Side/position identity: resolved by protocol, not hardware. The moment a connector's dock-detect fires (parent infers this by polling its I2C mux channels for an ACK — no dedicated interrupt pin needed either), the parent's first transaction to the child is a one-byte identity write (side, and for a chain, position). The child just stores it. No strap resistors, no extra pins, works identically whichever of the child's connector footprints is physically mated (single-connector dock or mid-chain with two simultaneously mated).

Functional requirements

#Requirement
FR1Exactly one USB-C cable connected across the whole assembly at any time.
FR2Every board — parent and each child — is a fully independent standalone USB HID keyboard when it's the one cabled.
FR3Parent exposes multiple dock connectors (baseline 2: LEFT, RIGHT, per ba-chroboard).
FR4Parent supports 0..N children docked simultaneously, any combination of connectors populated.
FR5A docked child's matrix (+ encoders) is folded into the parent's matrix; parent holds sole HID/keycode authority for it.
FR6A docked child performs no independent HID or host communication — pure input relay.
FR7Every populated OLED runs locally off its own board's private I2C0 bus, live in both STANDALONE and DOCKED_SLAVE.
FR8Landscape mounting: a child's multiple connector footprints (however many edges are populated) are wired in parallel to the same 2 GPIO (I2C1 SDA/SCL) — only one is ever mated at a time in this mode, so it costs zero extra GPIO. Footprint pin order must be rotationally symmetric so mating lines up correctly regardless of which edge is used. Orientation is not self-discovered by the child — because all footprints share one electrical net, the child cannot tell which of its own footprints is actually mated. Instead, orientation is a property of which parent connector it's docked to: the parent already knows which of its own connectors answered (fixed by wiring, same as side identity), so it includes the expected mounting orientation in the same identity-write handshake (e.g. LEFT/RIGHT = portrait, a dedicated TOP connector = landscape). This is enforced mechanically, not electrically — a child's landscape-facing footprint must be keyed (magnet polarity / connector shape) so it can only physically mate with the parent port defined for that orientation, not interchangeably with the portrait ports.
FR9Standalone↔docked transitions are automatic on physical connect/disconnect, no user action beyond plugging.
FR10Fan-out: parent supports N directly-attached children via an I2C multiplexer (e.g. TCA9548A) — parent GPIO cost is a flat 2 pins (to the mux) regardless of N; each mux channel is electrically isolated so children can use a fixed, unstrapped I2C address.
FR11Chaining (scoped): a child can pass the dock bus through to one further child behind it (MAIN ← PAD ← PAD), target depth ~2-3 pads. This reuses the same shared-bus wiring as FR8 (in/out connector contacts on one pad are just two physical taps on the same internal I2C1 net) — still 2 GPIO per pad even with 2 connectors simultaneously mated. Each pad determines its chain position via the same identity-write handshake as FR-side-identity, extended to also carry "which physical edge is upstream" for keymap orientation.

Non-functional requirements

#Requirement
NFR1Connector is fixed at 4 conductors (GND/VCC/SDA/SCL) regardless of child complexity, connector count, landscape footprints, or chain position.
NFR2Magnetic pogo connector — physical alignment + retention, tool-free connect/disconnect. Part: HytePro M411P, 4-pin, 2.20mm pitch, gold-plated spring pins + NdFeB magnets (~600g pull), rated 5-24V/3A per pin (far beyond our 3.3V/I2C-logic needs). Sold and footprinted as a genuine male/female pair (Plug/Receptacle), not a symmetric part — see NFR3. KiCad symbol/footprint: already available via the marbastlib library (marbastlib-various.pretty, CON_HytePro_M411P_{Plug,Receptacle}_1x04-P2.20mm_Horizontal{,_FlushMount}), wired to this project's fp-lib-table. Use the _FlushMount variant — it's drawn to sit flush with the PCB edge, matching a dock connector's actual mounting need. Schematic side stays a plain generic 4-pin connector symbol (Connector:Conn_01x04_Pin); only the Footprint field points at the marbastlib part. ba-chropad's J2 is wired up this way (Plug, portrait connector) as the first instance.
NFR3Connector is keyed (mechanically or electrically) against reversed mating; if reversal is physically possible, it must be electrically safe. Gender-pairing constraint (newly surfaced): because NFR2's part is a true male/female pair, every mated joint needs one Plug + one Receptacle — this is a new naming/assignment problem on top of side/orientation identity (FR8), not solved by it. Working default: parent ports = Receptacle (fixed pads on the stationary hub), child's primary/portrait port = Plug (spring pins on the mobile board) — applied to ba-chropad's J2. Still open: a child that needs to mate with another child directly (the rotate-90 "mini split" scenario) can't use a uniform gender per board — it needs gender assigned per edge, not per board (e.g. every child's "left" edge is always Plug, "right" always Receptacle, so any two same-model children can dock left-to-right regardless of which physical unit they are). Needs a final convention once landscape/mini-split footprints are actually laid out.
NFR4I2C bus survives hot-plug/unplug of a child without locking up or requiring a parent power cycle (bus-timeout/recovery routine; consider a bus buffer like P82B96 on the connector line for signal integrity).
NFR5Dock/undock → firmware mode switch is near-instant — achieved via periodic I2C mux-channel polling (ACK/NACK), not a dedicated interrupt pin.
NFR6Dock-detect and I2C-relay logic is a shared module, not duplicated per board.
NFR7Reuses existing bachro-pad-v1 hardware (RP2040-Zero, MCP23017, OLED) for the child role with minimal rework — GP14/15 (currently SPLIT_TX/SPLIT_RX) repurpose directly to the connector-facing I2C1 bus without claiming new GPIO.
NFR8Each parent mux channel is electrically isolated from the others — a fault, chain, or address collision on one connector cannot affect another.
NFR9Chain depth beyond the validated practical limit (target ~3-5 hops, bounded by I2C bus capacitance and cumulative pogo contact resistance) requires active bus-repeater hardware and is explicitly out of scope for the initial design.
NFR10Idle/unmated connector footprints (landscape and chain-out contacts not currently in use) are exposed live contacts — enclosure/mechanical design should minimize accidental bridging.

Domain logic notes (implementation-level, not yet in schematic)

  • Matrix scanning: direct RP2040 GPIO on every board, not MCP23017. ba-chropad's 6x4 grid = 10 GPIO (4 rows + 6 cols, or 6+4 either orientation).
  • MCP23017 usage: local-bus only (I2C0), for encoders if a board has more than a handful (as in the original bachro-pad-v1's 16-position driver). Never appears on the connector — the connector (I2C1) only ever carries a board's own RP2040 acting as I2C slave, exposing an aggregated register map it built itself. The parent never talks to a child's MCP23017 directly. For a small encoder count, direct-GPIO + RP2040 PIO quadrature decode is a viable alternative to an MCP23017, trading pins for BOM.
  • GPIO budget, ba-chropad (6x4, no chain/landscape yet costed): 10 (matrix) + 2 (I2C0 local) + 2 (I2C1 connector) = 14 GPIO, fits a Waveshare RP2040-Zero's 20 exposed pins with room to spare. Landscape (FR8) and chaining (FR11) add 0 further GPIO under the shared-bus wiring approach.
  • Parent controller: budget is tighter (own matrix + mux control bus
    • local OLED bus), and it's a from-scratch board — lean toward a bare RP2040 (~26-29 usable GPIO) rather than a compact module like the RP2040-Zero.

Success criteria

  1. Lone child, own USB-C only → enumerates standalone, all keys/encoders work, OLED shows status.
  2. Lone parent, own USB-C only, nothing docked → enumerates standalone over its own matrix.
  3. Parent + 1 child (any connector), parent's USB-C only → single HID device, combined matrix, child's own cable never connected.
  4. Parent + full connector count populated with children, parent's USB-C only → single HID device, all matrices combined.
  5. Undocking a child mid-session doesn't hang the parent's I2C bus or require a reset.
  6. Docking a child mid-session (hot-plug) brings it online without replugging the parent.
  7. Two+ children docked simultaneously on different connectors, identical hardware → no I2C address collision, each independently readable via its own mux channel.
  8. All populated OLEDs show live local status simultaneously, in every cable/dock combination.
  9. Backward/flipped docking either can't physically happen, or causes no damage if it does.
  10. A populated I2C mux correctly enumerates and independently polls each directly-attached child up to the mux's channel count.
  11. A child rotated to use a different connector footprint (landscape) works identically to its default orientation, with correctly remapped keymap.
  12. A chain of 2 pads behind one connector both function correctly and are individually addressable with no collision.
  13. A chain of 3 pads behind one connector functions correctly (stretch validation of the practical hop ceiling before repeater hardware is required).

Open questions

  • Confirm the ba-chore/ba-chropad/ba-chroboard role mapping above — inferred from KLE layout shape, not stated explicitly anywhere in the bootstrap.
  • Parent connector count (N) — baseline 2 (LEFT/RIGHT) per ba-chroboard's reference layout; confirm this is the target, not just a preview artifact of the generator.
  • Connector part chosen: HytePro M411P (4-pin, 2.20mm pitch magnetic pogo, marbastlib footprints) — see NFR2. Keying is inherent to the part (magnet + housing shape prevent reversal); no separate D-shape needed.
  • Connector gender convention — parent=Receptacle/child-primary=Plug is a working default (see NFR3), but per-edge gender assignment for landscape ports and child-to-child mating isn't finalized.
  • Chain auto-addressing protocol — needs an actual design pass (how a pad discovers "I'm position 2 in this chain" and relays that to the one behind it); scoped as required by FR11 but not yet specified.
  • I2C mux part selection — TCA9548A assumed as a placeholder; confirm channel count and hot-plug behavior suit the design.
  • Controller parts — parent: bare RP2040 vs. a specific breakout module, not yet chosen. Child: RP2040-Zero reuse assumed from bachro-pad-v1, not yet confirmed for this new board.

Parts

433
QtyValueFootprintReferences
108CCapacitor_SMD:C_0603_1608MetricC1, C10, C11, C12, C13, C14, C15, C100, C101, C102, C103, C104, C105, C106, C107, C108 +92
108DDiode_SMD:D_SOD-123FD1, D10, D11, D12, D13, D14, D15, D100, D101, D102, D103, D104, D105, D106, D107, D108 +92
108SK6812MINI-ELED_SMD:LED_SK6812MINI-E_3.2x2.8mm_P1.5mm_ReverseMountLED1, LED10, LED11, LED12, LED13, LED14, LED15, LED100, LED101, LED102, LED103, LED104, LED105, LED106, LED107, LED108 +92
92SW_PushSwitch_Keyboard_Kailh:SW_Kailh_Choc_V1V2_1.00uSW10, SW11, SW12, SW13, SW14, SW20, SW21, SW22, SW100, SW101, SW103, SW104, SW105, SW106, SW107, SW108 +76
9RotaryEncoder_SwitchRotary_Encoder:RotaryEncoder_Alps_EC11E-Switch_Vertical_H20mmSW1, SW2, SW3, SW4, SW5, SW16, SW17, SW18, SW19
3SW_PushSwitch_Keyboard_Kailh:SW_Kailh_Choc_V1V2_1.25uSW62, SW72, SW99
2SW_PushSwitch_Keyboard_Kailh:SW_Kailh_Choc_V1V2_1.50uSW15, SW34
1SW_PushSwitch_Keyboard_Kailh:SW_Kailh_Choc_V1V2_1.75uSW81
1SW_PushSwitch_Keyboard_Kailh:SW_Kailh_Choc_V1V2_6.25uSW102
1SW_stabMounting_Keyboard_Stabilizer:Stabilizer_Cherry_MX_6.25uST102

More from JoniBach/bachro-board-v1

5
  • 2 layers416.6 × 140 mmBach board, the printed circuit board in 3D

    Bach board

    JoniBach/bachro-board-v1

    One main keyboard ("parent") with magnetic dock connectors on its edges, and detachable macropads ("children") that either run standalone on their own USB-C or dock to the parent as passive matrix extensions.

    283 parts
  • 2 layers211 × 100.8 mmCore, the printed circuit board in 3D

    Core

    JoniBach/bachro-board-v1

    One main keyboard ("parent") with magnetic dock connectors on its edges, and detachable macropads ("children") that either run standalone on their own USB-C or dock to the parent as passive matrix extensions.

    241 parts
  • 2 layers225 × 140 mmCore, the printed circuit board in 3D

    Core

    JoniBach/bachro-board-v1

    One main keyboard ("parent") with magnetic dock connectors on its edges, and detachable macropads ("children") that either run standalone on their own USB-C or dock to the parent as passive matrix extensions.

    141 parts
  • 2 layers68.1 × 100.8 mmPad, the printed circuit board in 3D

    Pad

    JoniBach/bachro-board-v1

    One main keyboard ("parent") with magnetic dock connectors on its edges, and detachable macropads ("children") that either run standalone on their own USB-C or dock to the parent as passive matrix extensions.

    96 parts
  • 2 layers80 × 140 mmPad m, the printed circuit board in 3D

    Pad m

    JoniBach/bachro-board-v1

    One main keyboard ("parent") with magnetic dock connectors on its edges, and detachable macropads ("children") that either run standalone on their own USB-C or dock to the parent as passive matrix extensions.

    71 parts

Similar boards

  • 4 layers234 × 84 mmMain panel, the printed circuit board in 3D

    Main panel

    google/mozc-devices

    Circuit diagrams and firmware source code for Gboard DIY keyboards

    234 parts3kApache-2.0
  • 4 layers180.8 × 300.3 mmDilemma, the printed circuit board in 3D

    Dilemma

    Bastardkb/Dilemma

    The Dilemma is a vertical stagger low-profile keyboard with mods.

    383 parts590
  • 4 layers48 × 32 mmFlatSat, the printed circuit board in 3D

    FlatSat

    Pwnsat/FlatSat

    Flatsat v1.0 is a hardware based platform for aerospace cybersecurity research

    106 parts575GPL-2.0
  • 2 layersDemo, the printed circuit board in 3D

    Demo

    adamws/kicad-kbplacer

    KiCad plugin for automatic keyboard's key placement and routing

    48 parts547GPL-3.0
  • 2 layers97 × 78.5 mmDumbpad, the printed circuit board in 3D

    Dumbpad

    imchipwood/dumbpad

    Simple 4x4 numpad with rotary encoder. Powered by QMK via ATmega32u4 Pro Micro

    62 parts517GPL-2.0
  • 4 layers82.5 × 39.4 mmV4head, the printed circuit board in 3D

    V4head

    makerforgetech/modular-biped

    An open source framework for creating a bipedal modular companion robot.

    26 parts493GPL-3.0
  • 2 layers115.7 × 95.7 mmFifi split keeb, the printed circuit board in 3D

    Fifi split keeb

    raychengy/fifi_split_keeb

    Fifi Keyboard 🐶 ⌨️

    66 parts334
  • 4 layers70 × 54 mmPicoLab, the printed circuit board in 3D

    PicoLab

    CoretechR/PicoLab

    Web-GUI Embedded Multitool

    285 parts327GPL-3.0

Questions

How big is the Keyboard PCB?

It measures 372.9 × 100.8 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Keyboard use?

433 parts, built around the SK6812MINI-E. 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 Keyboard KiCad files?

From the JoniBach/bachro-board-v1 repository on GitHub, at the commit this page was made from: the board is ba-chroboard/keyboard/keyboard.kicad_pcb and its schematic ba-chroboard/keyboard/keyboard-key-matrix.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Keyboard design in my own project?

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