0
mirror of https://github.com/torvalds/GuitarPedal.git synced 2026-06-06 04:51:54 +00:00
Files
Linus Torvalds 3358fa4d9a Add plain MIDI-control only pedal design
This has no UI except for a single stomp switch and LED, since the plan
is that it replaces it all with with just MIDI control.

I already have working MIDI-over-USB (with horribly inconvenient USB-C
port placement on the previous board, but that's a historical accident
from when I didn't realize that I actually want to use that connector
for more than programming).

But this also adds 3.5mm TRS jacks for MIDI input and output, so that I
could attempt to do that too.

Do I know what I am doing? No.

Has that stopped me before? Also no.

The plan is that this should work together with the existing audio jack
board and connect to it over the 12P FFC cable exactly like the "real"
pedal did.  So exactly like that board, this depends on that external
board with the TI5112 codec, audio jacks and 9V power jack.

Except it now brings out the USB-C port properly - it's no longer
designed to be just a debug and programming port.  And because it has no
real UI it's all much smaller.  So this board is 48x48mm, and I'll just
do a 3D-printed enclosure for testing.

The audio jack board mounts under this board (with components facing
down, that's how it was all designed).  So audio jacks and 9V power jack
comes out the top of this pedal exactly like the previous one.

This board then goes on top of the audio jack board (with components
facing up, so the two boards have their unpopulated sides against each
other, probably with some 3D-printed spacer between).  The board has a
slot cut out of it, so that the FFC cable can slip out to the audio jack
board below it.

The USB-C connector from this board will be right above the 9V power
jack, and the MIDI TRS jacks come out on the left-hand side for entirely
random reasons (mostly because that made board layout easier).

Of course, I've never done MIDI hw before, so I may have screwed that
part up.  It's supposed to be Type A MIDI, with all the proper bells and
whistles: optocoupler with reverse polarity protection on the LED,
push-pull 5V level shifting buffering out the output, proper current-
limiting resistors, the whole nine yards.

But it's really just me googling things until I felt reasonably
confident I understood the (very simple) electrical details.

I haven't written any of the MIDI hw control code, but it's just a UART
running at 31.250 kbps, and the protocol is already done.  So that part
shouldn't be the problem, as long as the hardware works.

But I won't be entirely surprised if none of this works.  It's not like
I even have any MIDI devices with TRS jacks, but I'm sure Amazon carries
random test equipment in the form of cheap audio toys.  That's how I
tested MIDI-over-USB ;)

And as is tradition, this does a couple of truly horrendously bad 3D
models for the parts I'm using so that I have a rough idea what the
layout will look like.

Somewhat strangely, I also had to do the footprint for the very common
PJ-320D TRRS connector - because the one that comes with KiCad was just
plain wrong and didn't match the datasheet.  Maybe one of those
"different manufacturers" thing, but I suspect it was just wrong.

The kicad provided footprint was "close enough" that there was enough
overlap between pads and board design that it probably mostly worked in
practice, even if things didn't quite line up.  Possibly done with
calipers and measuring rather than by the datasheet.

And maybe the datasheet is wrong too, but my footprint at least matches
the part layout at JLCPCB.  It does have an offset compared to the
actual part when ordering, but that's a trivial "fix at order time"
issue.

Not unusual or unexpected: JLCPCB uses the center of the part, while I
centered it at a logical place that made the datasheet numbers easy too.
It happens with other kicad footprints, with JLCPCB having different
initial rotation and centerpoints for parts.

I also had to add a footprint for the stomp switch that Ricky pointed me
at, because I'm done soldering wires by hand.  This one goes on the
board.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-06-04 19:26:24 -07:00
..
2026-05-13 16:39:41 -07:00