Simple way to add controllers to custom Zynthian

Hi there,

I’ve started building a Zynthian using a RBPi4, a 5 inch capacitive touch screen using the DSI port and a raspiaudio sound card. My original plan was to start with an encoderless version (hence the larger + capacitive screen). So far so good: it makes sounds and the touchscreen works.

However it turns out not to be very practical : lists scroll way too fast, you often trigger unwanted actions (due to the fact the touch screen must emulate two different encoder actions - turning AND pushing - => I often get asked if I really want to turn the device off when scrolling through a long list with the Select virtual knob for instance), etc.

So, I’m considering adding 4 encoders, ideally with no soldering at all or as little as possible. But how? There’s the V4 controller’s set, but it’s meant to be hooked up to the Zynscreen, which I don’t have. There’s the V2 all-in-one module kit + V2 encoders but besides the fact it may be more soldering than desired and it is pricier (62€ for adding 4 encoders), I’m not sure about its usefulness: the MCP23017 GPIO expander module is said to be needed for “connecting the controller modules without exhausting the RBPi GPIO ports”. The thing is that I don’t care about MIDI (USB is enough for me), all I need is the 4 encoders, and given my display uses the DSI port it doesn’t use any GPIO. As for the sound card, it only takes up a few of them (see link above), and offers a connector for accessing the remaining available GPIOs. Isn’t there a simple way like buying the V4 controller’s set, removing the connectors intended for the zynscreen board and wiring them to the RPi4 GPIO through the sound card 25 pin connector? Thanks in advance for your advice.

That’s almost a :face_with_monocle: in itself . . .

Yes, I’d agree. A mouse is a good compromise and it’s the reason you get the cursor on/off option in display set up.

You can produce a fairly responsive environment with a wireless mouse and a rf dongle …

You can wire the encoders straight to the i/o pins on the pi. Indeed back when the earth cooled that was how it was done. We’ve documented several of these …

and the webconf set up effortlessly supports it all ( Once you’ve worked your way through the mapping … There’s a chart out there )

If bare metal engineering isn’t quite your thing then

The AllinOne board his what I would use, and just ignore the MIDI bits…

It’s really much more about how you are going to mount things and the type of enclosure you are going to use., and it the pi world that means you are really worrying about how to get access to the Power connectors, the usb, ethernet & the SSD especially if you’ve bolted your pi directly to the back of the touchscreen.

You can also use a USB (QWERTY or similar) keyboard to control the unit.

Yes, surprisingly enough after installing the sound card driver I used the quite unrelated settings below and it worked

  • Audio: HifiBerry DAC+
  • Display: waveshare 5’ HDMI+GPIO

That will be the next challenge: no enclosure for now, the pi is bolted to the back of the screen and the sound card plugged on the pi. Unfortunately as it’s a 5 inch displaya nd not a 3.5, it’s larger than the pi (and the sound card is sized for a Pi Zero so it’s also smaller than the Pi 4, but here you can easily solder wires and attach remote RCA or Jack connectors). So, as is, it would require a very oddly shaped enclosure, therefore I’m more considering having at least the display attached to the front panel of the enclosure and the pi to the back panel in a corner for easy access to ports. The enclosure itself would likely be made of laser (or hand)-cut wood. Doesn’t need to be too fancy as long as the needed port are accessible.

OK, so if I get the V3/4 controller set, connect them to some free pi GPIOs and point to them in the webconf I’m supposedly good, then? The front panel wood must just be thin enough for being able to mount the controllers through it