A DIY MIDI file player with Fluidsynth, Pirate Audio and Raspberry PI Zero 2

Опубликовано: 27 Ноябрь 2025
на канале: Floyd Steinberg
15,198
478

In this video, I'm building a General MIDI file player with a "Pimoroni Pirate Audio" board, a Raspberry PI 2 Zero and Python and FluidSynth. Table of contents:

00:00 demo 01
00:16 hello
00:31 parts needed
01:12 assemble
01:32 install raspbian 32 bit lite
01:53 boot and log in
02:16 install updates
02:31 install the audio board
03:02 install fluidsynth
03:38 install python and libraries
03:56 st7789 libraries and example codes and libopenblas
04:35 enable high priority mode
05:07 upload some midifiles and play back files from the command line
05:39 adding more soundfonts
05:50 a python script for playback control
07:40 you can add your ideas easily ;-)
07:50 conclusion
08:21 demo 02

Links:
Raspberry PI 2 Zero https://amzn.to/3YLBC8G
Pirate Audio board: https://shop.pimoroni.com/products/pi...
My Python script: https://github.com/mrfloydst
Raspberry PI imager: https://www.raspberrypi.com/software/

All command line commands:
Install 32 bit os lite, bookworm or bullseye

ssh to raspberrypi
sudo apt update
sudo apt upgrade
sudo apt install fluidsynth
sudo raspi-config - turn on spi and i2c
sudo nano /boot/firmware/config.txt, add

dtoverlay=hifiberry-dac
gpio=25=op,dh

sudo apt-get install python3-rpi.gpio python3-spidev python3-pip python3-pil python3-numpy
sudo pip3 install pidi-display-st7789 --break-system-packages
sudo pip3 install pyfluidsynth --break-system-packages
sudo apt install git

git clone https://github.com/pimoroni/st7789-py...
cd st7789-python/examples/
sudo apt install libopenblas-dev
python3 scrolling-text.py

sudo nano /etc/security/limits.conf

@audio - rtprio 90
@audio - memlock unlimited

sudo reboot

cd /usr/share/sounds/sf2

sudo wget http://ntonyx.com/soft/32MbGMStereo.sf2
sudo wget https://musical-artifacts.com/artifac...

(Download any MIDI file)

fluidsynth -a alsa -n -i /usr/share/sounds/sf2/FluidR3_GM.sf2 midifile.mid

HÄLP ZIS CHANNEL
https://distrokid.com/hyperfollow/flo...
  / floyd_steinberg  
https://floydsteinberg.gumroad.com/
https://floydsteinberg.bandcamp.com/
   / @mr_floydst  

Join us on Woody Piano Shack's Discord server:   / discord  

Get 7% off on DistroKid with this link http://distrokid.com/vip/floyd
PayPal.me https://www.paypal.me/alexselck

Shop a Huge Selection of Synths and Drum Machines at PerfectCircuit.com!
https://link.perfectcircuit.com/t/v1/...

Here's what I have in my setup at the moment. Want to have that, too? Please use the followings links and support me:

Yamaha EX5 https://www.ebay.com/sch/i.html?_nkw=...
Kasser Synths Arcade https://www.tindie.com/products/kasse...
Intech GRID: https://intech.studio/
MPC One, Novation PEAK, Reface DX, Source Audio Collider, Strymon Iridium, Zoom MS 70 CDR, Donner N-25, Akai EWI USB, Zoom R20, Zoom H5, Yamaha MT7, Roland Aira:
https://www.thomann.de/de/thlpg_3wyep...

Some bands / artists I've been following for a long time are (among others) Massive Attack, Pink Floyd, Pet Shop Boys, Archive, A-Ha, Yes, Porcupine Tree, John Mellencamp, Jean-Michel Jarre, Metallica, Peter Gabriel and Perturbator. So my music will kind of sound like those (without ever reaching the greatness of those artists, of course). :-)