Hi everyone,
first I want to say hello to this lovely community, since I am totally new to the board and to RPi stuff in general. I managed to assemble a basic Zynthian using a RPi5 with a 8" Waveshare HDMI Touch connected to my Focusrite Scarlett 2i4 and was already able to play some music, pushing some gigabyte-ish Steinway D samples to the machine and already used it in my bands rehearsal.
Next I wanted to put everything in a nice wooden cigar box and am now in the process of ordering stuff for it. Plans are for now:
- 4 Encoders to GPIO
- replace Focusrite with Hifiberry DAC+/2 ADC and add stereo I/O Jacks
Like already mentioned, I am completely new to the topic and could need some help. You can imagine I have tons of questions already, but to not flood this forum I’ll start with the encoder subject. I promise, I already read through all threads you can find by search terms “encoder”, “GPIO”, “MCP23017” and so on.
I created this table for my own conciderations:
Notes | BCM | WPI | Name | Pin | Pin | Name | WPI | BCM | Notes |
---|---|---|---|---|---|---|---|---|---|
Evtl. + All Enc | 3.3v | 1 | 2 | 5v | |||||
X HifiB | 2 | 8 | SDA.1 | 3 | 4 | 5v | |||
X HifiB | 3 | 9 | SCL.1 | 5 | 6 | GND 0v | free GND | ||
4 | 7 | GPIO.7 | 7 | 8 | TxD | 15 | 14 | X ZynMid | |
free GND | GND 0v | 9 | 10 | RxD | 16 | 15 | X ZynMid | ||
* | 17 | 0 | GPIO.0 | 11 | 12 | GPIO.1 | 1 | 18 | X HifiB |
* | 27 | 2 | GPIO.2 | 13 | 14 | GND 0v | free GND | ||
* | 22 | 3 | GPIO.3 | 15 | 16 | GPIO.4 | 4 | 23 | * |
3.3v | 17 | 18 | GPIO.5 | 5 | 24 | * | |||
10 | 12 | MOSI | 19 | 20 | GND 0v | free GND | |||
9 | 13 | MISO | 21 | 22 | GPIO.6 | 6 | 25 | * | |
11 | 14 | SCLK | 23 | 24 | CE0 | 10 | 8 | ||
free GND | GND 0v | 25 | 26 | CE1 | 11 | 7 | |||
0 | 30 | SDA.0 | 27 | 28 | SCL.0 | 31 | 1 | ||
* | 5 | 21 | GPIO.21 | 29 | 30 | GND 0v | free GND | ||
* | 6 | 22 | GPIO.22 | 31 | 32 | GPIO.26 | 26 | 12 | * |
* | 13 | 23 | GPIO.23 | 33 | 34 | GND 0v | free GND | ||
X HifiB | 19 | 24 | GPIO.24 | 35 | 36 | GPIO.27 | 27 | 16 | * |
* | 26 | 25 | GPIO.25 | 37 | 38 | GPIO.28 | 28 | 20 | X HifiB |
free GND | GND 0v | 39 | 40 | GPIO.29 | 29 | 21 | X HifiB |
While reading the corresponding thread about wiring encoders to RPi4 I cam across some wiring suggestions frim @wyleu . I noticed that both of them seem to use pins another post of the same thread recommends to avoid. As far as I understand from corresponding sources I should avoid Pins 3, 5, 8, 10, 12, 35, 38, 40 because of Zynthians Midi I/O and used Pins of the HifiBerry DACs. So I assume I could use the GPIOs marked with a “*” in any order. Do I get that right?
The other question is about the oftentimes mentioned capacitors. I understood from this forum that they might be needed, or not. From what I understood, I might consider to buy 4 100nF caps and 8 10nF caps and place them between the A(CLK), B(DT) and Switch(SW) pins of the encoder and the corresponding GPIO. My question would be if I can use any type of caps, like these. What I also learned by reading these threads is that I might or might not unsolder a resistor on the encoders pcb.
Ok, I’ll stop myself here. Thanks in advance for your kind help already.