[PLUGIN] MPD OLED - installation & configuration plugin

Maybe one way would be to start cava using GitHub - volumio/volumio-alsa-hook: Volumio Alsa Hook
It allows starts each time pcm is opened and closed.
This mecanism is used in FusionDsp to start and stop Camilladsp with new parameters.
In the plugin, volumio_fifo is set to only send s16_le

Thanks for the suggestion. If the hook action was to restart the mpd_oled service when the PCM parameters change then this might be infrequent enough that the inconvenience of blanking the screen briefly would be acceptable. A starting point, though, should be to see if it is possible to write the ALSA config in a way that avoids the parameter locking without stopping mpd_oled (or having to modify its code).

Ladies and gentlemen, what to use the USB / I2C converter to display

worked with PC SBC X12STN-C. I have a proposal for the MCP2221 converter, but I do not know if it is good.

1 Like

Hi krzysztoffilipak

The current version of mpd_oled uses the kernel driver for I2C, this means that if you plug in a USB device providing pins for an I2C connection, and it can be accessed through entries like /dev/i2c-0, then it might work with mpd_oled. It looks like the MCP2221 has a linux driver and works with the linux i2c-tools, so you might be in luck.

The Botland OLED looks like it is compatible with mpd_oled.

Adrian.

1 Like

It should work fine. Try installing the plugin and then run the i2c detection functionality in the settings page 🫡

1 Like

Great, thank you gentlemen @Adrii , @supercrab . So when it arrives, I’ll come back to this topic.

2 Likes

Hi all!
Thanks for all the work so far, I’m living in the hope to get two adafruit working someday.
But:
I can’t get one working when another SPI-Display is already and always connected to SPI0.0 and SPI0.1 (Touch). I’d need to get the definition changed to bus 1-6 as of Raspi4: I’ve connected it to SPI5_CS0. There’s indeed in the config.json some definition line which is not shown in the GUI, but writing a “5” inside doesn’t seem to work.
Help?

I have the same oled display and it works perfectly with the mpd_oled 1.1.1 plugin

1 Like

You don’t need the USB to MCP2221 device for using the OLED screen by the way. You can just plug the screen directly into the pins on the pi.

What is the line in the config?

There are a few SPI configs you can try in the plugin’s settings page.

I have a pc supermicro not a PI
only there is smbus, but it’s probably not to be used?

It might work out. You could try the configuration steps in the following video and see if you end up with /dev/i2c device entries.

Tutorial: Access the I2C Bus on any Desktop PC (The SMBus) - YouTube

I’m don’t think it’ll work :disappointed_relieved: I don’t know of anyone who has used it with a USB to GPIO expander.

Hi all,
I tried to get an overview over this whole thread but it’s quite difficult so I might pick something up that might have been solved already somewhere.

I’ve reflashed my build to the latest Volumio version.

I then installed MPD_OLED via the plugin manager and started the configuration. The OLED display (SSD1309) was correctly identified on 3c. However the display does not seem to run correctly. I can recognize that it’s displaying date, time and IP but depending on what of the 3 available I2C display types I choose from the drop down “OLED Display Type” it flickers more or less like an old TV with bad antenna signal and continuously changes brightness. Is there anyone that has experienced similar and knows how to fix that?

Additionally if I want to play music I receive following error:

Failed to open “alsa” (alsa); Failed to open ALSA device “volumio”: Device or resource busy

Not sure if this might be related to the plugin as well?

Thanks to anyone providing a hint!

Is your 5V properly connected. I have seen the same issue. in my case the 5V connection was bad. So the MPD_OLED tries to feed itself with the GPIO pin, As this doesn’t has enough power the screen started to flicker/dim/stall. Pretty similar to what you’re describing.

Hi all,
now, the plugin uses /data/configuration/system_hardware/mpd_oled/config.json for configuration. There is “spiCS” - shown and changeable in GUI - and “spiLabel” - not seen in GUI. But it seems to have no function?
But what I need is the definition of the spi-channel: Raspi4 has spi0-6. Because of hard-wired TFT-Touch on spi0cs0 and spi0cs1 I had to use other spi-devices. spi6 uses the upper pins not used by the touch display (MOSI=pin38, SCLK=pin40, cs0=pin12).
So ideally, there’d be a GUI-option to choose the spidev.

Ah, yes, it’s used to populate the default text in the SPI CS line combo :slight_smile: It just happens to not appear in the code but is definitely used.

This plugin is just a wrapper for mpd_oled. I didn’t write mpd_oled I lhecked the code and SPI2-6 is not supported presumably because this is only found on Pi4.

You could raise an issue for Adrian and if it gets resolved I’ll add it to the plugin GitHub - antiprism/mpd_oled: MPD, Volumio, RuneAudio and Moode OLED status and spectrum display for Raspberry Pi (and similar)

Try stopping the plugin and using the instructions for installing mpd_oled for volumio this will help rule out any issues with the plugin GitHub - antiprism/mpd_oled: MPD, Volumio, RuneAudio and Moode OLED status and spectrum display for Raspberry Pi (and similar)

1 Like

Hi chefmagier

The current version of mpd_oled does not use the kernel driver for SPI, it uses bcm2835: C library for Broadcom BCM 2835 as used in Raspberry Pi (and the version used is “1.61 2020-01-11”). The driver supports the Pi4, but I am unsure if it supports anything other that SPI0 and SPI1.

The development version of mpd_oled GitHub - antiprism/mpd_oled_dev: mpd_oled development version (unstable) uses the kernel driver for SPI, and so if the kernel makes other SPI buses available then mpd_oled could be configured to use them. There is no plugin version.

Adrian.

1 Like

Like Adrian says, your best bet is to use the development branch of mpd_oled or put your screen on SPI0 or SPI1 :smiley: