#ssd1315 — Public Fediverse posts
Live and recent posts from across the Fediverse tagged #ssd1315, aggregated by home.social.
-
Almost “All in one” MiniDexed IO Options
As I was browsing around I happened to notice a couple of interesting add-on boards that comprise a OLED display, rotary encoder and some buttons.
With the addition of a I2S DAC (or just using the existing PWM output) these make a really interesting option for MiniDexed IO.
Warning! I strongly recommend using old or second hand equipment for your experiments. I am not responsible for any damage to expensive instruments!
If you are new to microcontrollers and single board computers, see the Getting Started pages.
The Displays
There are lots of cheap display boards out there. These are the boards I’ve been looking at:
Which are called some variation of the following:
- “0.96 inch OLED IIC 12864 OLED Display with 4×4 key I2C SSD1315 LCD Screen”.
- “1.3 inch OLED display screen with EC11 rotary encoder module IIC”.
- “0.96 inch OLED display screen with EC11 rotary encoder module IIC”.
These particular ones have the following display parameters
SH1106 (1.3″), SSD1306 (0.96″), and SSD1315 (0.96″ with buttons).
1.3″ Encoder Display0.96″ Encoder display0.96″ button displaySH1106SSD1306SSD1315128×64128×64128×642 Buttons2 Buttons4 ButtonsSwitched Rotary EncoderSwitched Rotary EncoderSSD1306 is directly supported by MiniDexed, but the other two are not. But it turns out that the SSD1315 display works fine as a SSD1306 and all three have the same I2C addressing scheme – 0x3C is the default.
The SH1106 based display however will need some updates to the core operating environment used by MiniDexed before it can be used, so for now that one can’t be used.
0.96″ Encoder Display
The following wiring and configuration should allow the use of this display with MiniDexed.
Raspberry Pi GPIO Connections
Display VCC3V35VDisplay SDAGPIO 2 SDA5VDAC VINDisplay SCLGPIO 3 SCLGNDDisplay GNDGPIO 4GPIO 14 TXDGNDGPIO 15 RXDOpt: MIDI INGPIO 17GPIO 18 PCM CLKDAC BCKGPIO 27GNDGPIO 22GPIO 233V3GPIO 24Display TRBGPIO 10GNDDisplay TRAGPIO 9GPIO 25Display PSHGPIO 11GPIO 8GNDGPIO 7ID_SDID_SCDisplay BAKGPIO 5GNDDisplay CONGPIO 6GPIO 12GPIO 13GNDDAC SCK / GNDDAC LRCKGPIO 19 PCM FSGPIO 16GPIO 26GPIO 20DAC GNDGNDGPIO 21 PCM DOUTDAC DATANote: I ended up swapping TRA/TRB over (which can be done either in the wiring or in the definitions in minidexed.ini) to make the encoder operate in the direction I wanted.
I’ve also chosen to wire the “CONFIRM” button as a HOME button, but this could be used for SELECT if required. I’m using the encoders switch for SELECT.
The display board doesn’t include any audio so a I2S DAC is highly recommended, which has to be connected separately. It is also possible to connect up a MIDI IN circuit to GPIO 15 (RXD) if required.
MiniDexed.ini Configuration
SoundDevice=i2s
LCDEnabled=1
SSD1306LCDI2CAddress=0x3C
SSD1306LCDWidth=128
SSD1306LCDHeight=64
ButtonPinBack=5
ButtonActionBack=click
ButtonPinSelect=11
ButtonActionSelect=click
ButtonPinHome=6
ButtonActionHome=click
EncoderEnabled=1
EncoderPinClock=10
EncoderPinData=9It is possible to leave SSD1306LCDHeight=32 and then the display is double-height, but it is also a little grainy, so I prefer just to use half the display with a “fuller” text myself.
Note: my display came with a knob for the encoder that was slightly too tall. When fully pushed on, it stopped the encoder’s switch from working properly!
0.96″ Button Display
Here is how to use this display with MiniDexed.
Raspberry Pi GPIO Connections
Display VCC3V35VDisplay SDAGPIO 2 SDA5VDAC VINDisplay SCLGPIO 3 SCLGNDDisplay GNDGPIO 4GPIO 14 TXDGNDGPIO 15 RXDOpt: MIDI INGPIO 17GPIO 18 PCM CLKDAC BCKGPIO 27GNDGPIO 22GPIO 233V3GPIO 24Display K1GPIO 10GNDDisplay K2GPIO 9GPIO 25Display K3GPIO 11GPIO 8GNDGPIO 7ID_SDID_SCDisplay K4GPIO 5GNDGPIO 6GPIO 12GPIO 13GNDDAC SCK / GNDDAC LRCKGPIO 19 PCM FSGPIO 16GPIO 26GPIO 20DAC GNDGNDGPIO 21 PCM DOUTDAC DATAAs there are only four buttons, I’m mapping them to Next, Prev, Select and Back.
This is the minidexed.ini configuration.
SoundDevice=i2s
LCDEnabled=1
SSD1306LCDI2CAddress=0x3C
SSD1306LCDWidth=128
SSD1306LCDHeight=64
ButtonPinPrev=10
ButtonActionPrev=click
ButtonPinNext=9
ButtonActionNext=click
ButtonPinBack=5
ButtonActionBack=click
ButtonPinSelect=11
ButtonActionSelect=click
EncoderEnabled=0The rotary encoder is on by default, so needs turning off.
Closing Thoughts
I was hoping to be able to get all three up and running, but although the third display is recognised and can be poked to some degree, at the moment it is just showing a garbled output. I suspect it will need some alternative mappings or something.
It was nice to see that the ssd1315 just worked as is.
I notice that MT32-Pi has support for SH1106 and it seems like a relatively thin layer on top of the core SSD1306 support, so I’ll take a look and see if I can get this into circle in a useful way. It would certainly be nice to be able to add support for more displays in MiniDexed.
Kevin